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

coerce and rotate pvgis TMY data to desired tz and year #2138

Merged
merged 26 commits into from
Aug 16, 2024
Merged
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
883cfbe
coerce and rotate pvgis TMY data to desired tz and year
mikofski Jul 19, 2024
7e6e4c0
test get_pvgis_tmy_coerce_year
mikofski Jul 19, 2024
84d4695
fix flake8 in test_pvgis_coerce_year
mikofski Jul 19, 2024
3e42075
remove iloc for index in test pvgis coerce
mikofski Jul 19, 2024
d0bd0a0
deal with leap year in pvgis when coercing
mikofski Jul 19, 2024
ec482ac
fix space around operator in coerce pvgis
mikofski Jul 19, 2024
883ced8
fix pd.Timestamp in pvgis coerce year
mikofski Jul 19, 2024
dd2c85f
Update v0.11.1 what's new for coerce pvgis tmy
mikofski Jul 20, 2024
31800e9
replace year and tzinfo in pvgis_tmy coerce year
mikofski Jul 27, 2024
72c55f6
remove unused imports from pvgis.py for flake8
mikofski Jul 27, 2024
0735183
change private function name to _coerce_and_roll_pvgis_tmy
mikofski Jul 27, 2024
2059dc6
spot check rolled pvgis TMY values after converting tz
mikofski Jul 27, 2024
a38cf9a
Update utc_offset description
mikofski Jul 31, 2024
440e780
change coerce_year and utc_offset defaults to None in pvgis TMY
mikofski Jul 31, 2024
4fd05fb
rename roll_utc_offset in get_pvgis_tmy
mikofski Jul 31, 2024
1b92d40
Update pvlib/iotools/pvgis.py with suggestions
mikofski Aug 1, 2024
43ce3c4
Update docs/sphinx/source/whatsnew/v0.11.1.rst
mikofski Aug 1, 2024
76c8ec6
Merge branch 'main' into coerce-and-rotate-pvgis
AdamRJensen Aug 5, 2024
d77a3d3
Merge branch 'main' into coerce-and-rotate-pvgis
mikofski Aug 5, 2024
91c169e
rename _coerce_and_roll_tmy, remove 'pvgis'
mikofski Aug 6, 2024
1e9ee64
rename index with new tz in coerce pvgis tmy
mikofski Aug 6, 2024
d24e4f3
allow tz of None in _coerce_and_roll_tmy
mikofski Aug 6, 2024
f12571d
Merge branch 'main' into coerce-and-rotate-pvgis
mikofski Aug 13, 2024
fb2813d
clarify input tmy_data is UTC...
mikofski Aug 14, 2024
ac9dbb0
fix flake8 in _coerce_and_roll_tmy
mikofski Aug 14, 2024
9875521
Merge branch 'main' into coerce-and-rotate-pvgis
mikofski Aug 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
rename _coerce_and_roll_tmy, remove 'pvgis'
mikofski committed Aug 6, 2024
commit 91c169e1f0ac5c51eb9f1c750685de87bb6fe6d3
4 changes: 2 additions & 2 deletions pvlib/iotools/pvgis.py
Original file line number Diff line number Diff line change
@@ -390,7 +390,7 @@ def read_pvgis_hourly(filename, pvgis_format=None, map_variables=True):
raise ValueError(err_msg)


def _coerce_and_roll_pvgis_tmy(pvgis_data, tz, year):
def _coerce_and_roll_tmy(pvgis_data, tz, year):
"""
After converting TZ, roll dataframe so timeseries starts at midnight
and force all indices to a common year. Only works for integer TZ.
@@ -544,7 +544,7 @@ def get_pvgis_tmy(latitude, longitude, outputformat='json', usehorizon=True,
# coerce_year is None but utc_off isn't, set year to 1990
if coerce_year is None: # more explicit than (coerce_year or 1990)
coerce_year = 1990
data = _coerce_and_roll_pvgis_tmy(data, roll_utc_offset, coerce_year)
data = _coerce_and_roll_tmy(data, roll_utc_offset, coerce_year)

return data, months_selected, inputs, meta