atlite
atlite copied to clipboard
support runoff normalization for partial years with annual normalization data
Changes proposed in this Pull Request
It makes cutout.runoff(normalize_using_yearly=...) more lenient by supporting proportional scaling of partially represented years in the cutout, assuming even distribution of runoff throughout the year. In this case, a warning is printed due to the strong assumption.
Relevant for https://github.com/PyPSA/pypsa-eur/pull/1613 (e.g. July-June meteorological years, in case the original cutout does not span Jan-Dec for each year included)
This also means we can include hydro in the CI test of PyPSA-Eur, which uses only a week of weather data.
Checklist
- [x] Code changes are sufficiently documented; i.e. new functions contain docstrings and further explanations may be given in
doc. - ~[] Unit tests for new features were added (if applicable).~
- ~[] Newly introduced dependencies are added to
environment.yaml,environment_docs.yamlandsetup.py(if applicable).~ - [x] A note for the release notes
doc/release_notes.rstof the upcoming release is included. - [x] I consent to the release of this PR's code under the MIT license.