Skip to content
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

Setting the "capacity_factor_timeseries = True" the results seem not to change #345

Open
TimFuermann opened this issue Apr 11, 2024 · 2 comments

Comments

@TimFuermann
Copy link

atlite/atlite/convert.py

Lines 128 to 137 in c1e29e8

if capacity_factor or capacity_factor_timeseries:
if capacity_factor_timeseries:
res = da.rename("capacity factor")
else:
res = da.mean("time").rename("capacity factor")
res.attrs["units"] = "p.u."
return maybe_progressbar(res, show_progress, **dask_kwargs)
else:
res = da.sum("time", keep_attrs=True)
return maybe_progressbar(res, show_progress, **dask_kwargs)

By setting the "capacity_factor_timeseries = True" the results seem not to be changed and a single generation time series is returned.
The reason might be that the flag "capacity_factor_timeseries = True" cannot be used when only a layout (no matrix and shape) is given.
I believe that line 129 is only reached if no_args = True, which means that none of layout, shapes and matrix, need to be given, in order to execute the flag.

A possible fix could be to unindending the lines: L128-L137

@FabianHofmann
Copy link
Contributor

hey @TimFuermann, thanks for raising an issue, I am not sure what the expected dimension should when setting capacity_factor_timeseries. Would you mind creating a PR and make a suggestion on how to change it?

@TimFuermann
Copy link
Author

@FabianHofmann: Sure, I am on it. Best, Tim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants