-
Notifications
You must be signed in to change notification settings - Fork 1.1k
PVsyst inverter #1002
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I agree, The Sandia inverter model assumes that the efficiency curves evolve linearly as the input DC voltage changes; as @Peque has pointed out, a given device might not follow that linear behavior. An interpolation would be more general. |
Would it be interesting to support reading |
The ability to read in .OND files (inverters) and .PAN files (modules) would be a big help for people trying to transition to pvlib from PVSyst. |
I think @frivollier has shared some tools to read OND and PAN files. I would support adding capabilities to pvlib, either directly or by importing from @frivollier 's project if there's intention to maintain that project. |
CanadianSolar CASSYS is another source of code to parse and model inverters:
|
Despite some good intentions I won’t be maintaining or updating this
project to read PAN files but I could help anyone that want to take it
over.
Fred
On Tue, Jul 14, 2020 at 3:15 PM Cliff Hansen ***@***.***> wrote:
I think @frivollier <https://github.com/frivollier> has shared some tools
<https://github.com/frivollier/pvsyst_tools> to read OND and PAN files. I
would support adding capabilities to pvlib, either directly or by importing
from @frivollier <https://github.com/frivollier> 's project if there's
intention to maintain that project.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1002 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AALHKPXBNGXK6JPUQJ5CFGTR3SVGZANCNFSM4OZDEGPA>
.
--
Frederic
|
In #1199 (comment) @cwhanse said:
Just curious, is that still the case? Do we expect to ever be able to address this feature request? |
AFAIK, yes. |
Should we just close this issue? AFAIK pvsyst just interpolates between the curves to get the efficiency. I don't know how it compares to Sandia grid inverter model, but I think it can't be bad to have a function that just does that. I also think the ability to read PAN and OND files would be very helpful. And measurements from the CEC solar equipment lists too while we're at it. def interp_inverter_eff(eff_curves, pdc_timeseries, vdc_timeseries, voltages, method="quadratic"):
"""
interpolate inverter efficiency given 3 voltages
Parameters
----------
eff_curves : numpy.ndarray or pandas.DataFrame
table of efficiencies with indices or first column as the DC power monotonically
increasing and each consecutive column at a different monotonically increasing
voltage corresponding to the ``voltages`` parameter
pdc_timeseries : numpy.ndarray, pandas.Series, or pandas.DataFrame
vdc_timeseries : numpy.ndarray, pandas.Series, or pandas.DataFrame
voltages : numeric
a sequence or scalar of the corresponding nominal voltages, must be
monotonically increasing and length must be same as columns in ``eff_curves``
method : str
how to interpolate the efficiency if given 3 voltages
returns
-------
efficiency : numpy.ndarray or pandas.Series
"""
eff_curves = pd.DataFrame(eff_curves, index_col=0)
f = scipy.interpolate.interp1d(x=eff_curves.index, y=eff_curves)
eff = f(pdc_timeseries)
try:
num_volts = len(voltages)
except TypeError:
num_volts = 1
else:
if num_volts > 1:
g = scipy.interpolate.interp1d(x=voltages, y=eff.T, kind=method)
eff = g(vdc_timeseries)
return eff |
OK with me to close, or to keep the issue open. It would be nice to have the Pvsyst inverter model in pvlib, the real blocker is the lack of documentation. |
I'm not sure if the above function works, as you say, there's no docs - which according to the pvlib ethos means it doesn't go in - soo... how about a gallery example or we start a |
The interpolation is simple enough that I'm ok adding it with the docstring being the reference, if you are persuaded that there's demand for it. It would fill a gap between the Sandia/adriesse models (which require fitting) and the PVWatts model (a single parameter), in that this interpolation could work from the data in the CEC listing or from digitized datasheet curves. |
Does anyone else see the irony here? The opening line is:
And:
Please let the banks know! |
If you have some data and are tempted to use interpolation, I suggest you also give the fitting routine for the ADR inverter model a try. It is located here. This model is well-documented, and being based on the summation of physically explained losses it is pretty much constrained to produce physically correct efficiency curves. If there is enough demand I can move it to pvlib. |
Maybe we could join forces and publish a paper with a title like "Bankability assessment of inverter simulation models" in a publication that bankers read. |
There might be details of the PVSYST inverter model in the CASSYS
documentation.
https://github.com/CanadianSolar/CASSYS/tree/master/Documents%20and%20Help
On Sat, Apr 9, 2022 at 3:39 AM Anton Driesse ***@***.***> wrote:
Does anyone else see the irony here? The opening line is:
I would like to mimic pvsyst so as to be bankable
And:
It would be nice to have the Pvsyst inverter model in pvlib, the real
blocker is the lack of documentation.
Please let the banks know!
—
Reply to this email directly, view it on GitHub
<#1002 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AALHKPXJQJCH73SN5FOYRWLVEEX35ANCNFSM4OZDEGPA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
--
Frederic
|
We could implement the interpolation model described in CASSYS documentation, call it the CASSYS model, and point to the comparison with Pvsyst which shows the two models' results are close. |
Good idea, starts here. |
There are some graphs in these publications illustrating what can go wrong with generic numeric interpolation: https://www.researchgate.net/project/PV-System-Simulation-Software-Validation |
I also tried modifying @mikofski 's code to go line by line, it gives the correct curve orientation, but I had to add some new points at 0 for the scipy functions to complete the interpolation. This may give the curve a more linear shape [Figure 1]
|
Playing around with this a little bit more, here are pictures of different types of linear interpolations and their resulting quadratic interpolations: None give the expected output, so there must be something else that I am missing. |
I interpret the PVsyst description to be "piecewise interpolation". I don't think a linear least-squares fit to all points in each curve is what is meant; it wouldn't be my first interpretation for the word "interpolation", and it doesn't make sense to fit straight lines to the full efficiency curves anyway. The CASSYS implementation is also "piecewise" in the linear Pdc interpolation: I haven't run any code myself but @mikofski's code in #1002 (comment) looks right to me: linear interpolation (not least-squares fit) to get low/medium/high efficiencies for the given Pdc, then quadratic interpolation between those three efficiencies for the given Vdc. Maybe adding (0,0) is needed if the curves in the OND files don't include it already.
I can't make sense of that either. Strange. |
I agree, least squares would be throwing away good data points. |
mimic pvsyst
I would like to mimic pvsyst so as to be bankable
a pvsyst inverter
Inverter model: efficiency says:
Sandia grid inverter model
Any idea how the Sandia inverter model compares?
Other pvsyst inverters
There are 4 options single curve, Euro per weighted efficiency, etc..
See also grid inverter-efficiency curve
The text was updated successfully, but these errors were encountered: