Skip to content

Commit 17aed3a

Browse files
authored
Update MIDC variable mapping (#2006)
* Update midc VARIABLE_MAP * Add subscripts to dni mapping * Update v0.10.5.rst * Update midc.py * Fix whatsnew entries * Implement review changes
1 parent 77c2051 commit 17aed3a

File tree

2 files changed

+17
-10
lines changed

2 files changed

+17
-10
lines changed

docs/sphinx/source/whatsnew/v0.11.0.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ Breaking changes
99
~~~~~~~~~~~~~~~~
1010
* The deprecated ``pvlib.modelchain.basic_chain`` has now been removed. (:pull:`1862`)
1111
* Remove the `poa_horizontal_ratio` function and all of its references. (:issue:`1697`, :pull:`2021`)
12+
* Updated `~pvlib.iotools.MIDC_VARIABLE_MAP`~ to reflect
13+
changes in instrumentation. (:pull:`2006`)
1214
* ``pvlib.iotools.read_srml_month_from_solardat`` was deprecated in v0.10.0 and has
1315
now been completely removed. The function is replaced by :py:func:`~pvlib.iotools.get_srml()`.
1416
(:pull:`1779`, :pull:`1989`)

pvlib/iotools/midc.py

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,21 @@
2020
MIDC_VARIABLE_MAP = {
2121
'BMS': {
2222
'Global CMP22 (vent/cor) [W/m^2]': 'ghi',
23-
'Direct NIP [W/m^2]': 'dni',
23+
'Direct CHP1-1 [W/m^2]': 'dni_chp1',
24+
# NIP was mapped to dni for pvlib<=0.10.5
25+
'Direct NIP [W/m^2]': 'dni_nip',
2426
'Diffuse CM22-1 (vent/cor) [W/m^2]': 'dhi',
2527
'Avg Wind Speed @ 6ft [m/s]': 'wind_speed',
2628
'Tower Dry Bulb Temp [deg C]': 'temp_air',
2729
'Tower RH [%]': 'relative_humidity'},
2830
'UOSMRL': {
2931
'Global CMP22 [W/m^2]': 'ghi',
30-
'Direct NIP [W/m^2]': 'dni',
31-
'Diffuse Schenk [W/m^2]': 'dhi',
32+
'Direct CHP1 [W/m^2]': 'dni_chp1',
33+
'Diffuse [W/m^2]': 'dhi',
34+
# NIP was mapped to dni for pvlib<=0.10.5
35+
'Direct NIP [W/m^2]': 'dni_nip',
36+
# Schenk was mapped to dhi for pvlib<=0.10.5
37+
# 'Diffuse Schenk [W/m^2]': 'dhi',
3238
'Air Temperature [deg C]': 'temp_air',
3339
'Relative Humidity [%]': 'relative_humidity',
3440
'Avg Wind Speed @ 10m [m/s]': 'wind_speed'},
@@ -80,18 +86,17 @@
8086
'Air Temperature [deg C]': 'temp_air',
8187
'Rel Humidity [%]': 'relative_humidity',
8288
'Avg Wind Speed @ 3m [m/s]': 'wind_speed'},
83-
'VTIF': {
89+
'NWTC': {
8490
'Global Horizontal [W/m^2]': 'ghi',
8591
'Direct Normal [W/m^2]': 'dni',
8692
'Diffuse Horizontal [W/m^2]': 'dhi',
87-
'Air Temperature [deg C]': 'temp_air',
88-
'Avg Wind Speed @ 3m [m/s]': 'wind_speed',
89-
'Rel Humidity [%]': 'relative_humidity'},
90-
'NWTC': {
91-
'Global PSP [W/m^2]': 'ghi',
93+
# PSP instrument was removed Feb. 2021
94+
# PSP was mapped to ghi for pvlib<=0.10.5
95+
# 'Global PSP [W/m^2]': 'ghi',
9296
'Temperature @ 2m [deg C]': 'temp_air',
9397
'Avg Wind Speed @ 2m [m/s]': 'wind_speed',
94-
'Relative Humidity [%]': 'relative_humidity'}}
98+
'Relative Humidity [%]': 'relative_humidity'},
99+
}
95100

96101

97102
# Maps problematic timezones to 'Etc/GMT' for parsing.

0 commit comments

Comments
 (0)