PVNet 5.0.22__py3-none-any.whl → 5.0.24__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pvnet/models/late_fusion/late_fusion.py +12 -6
- pvnet/training/lightning_module.py +4 -4
- {pvnet-5.0.22.dist-info → pvnet-5.0.24.dist-info}/METADATA +1 -1
- {pvnet-5.0.22.dist-info → pvnet-5.0.24.dist-info}/RECORD +7 -7
- {pvnet-5.0.22.dist-info → pvnet-5.0.24.dist-info}/WHEEL +0 -0
- {pvnet-5.0.22.dist-info → pvnet-5.0.24.dist-info}/licenses/LICENSE +0 -0
- {pvnet-5.0.22.dist-info → pvnet-5.0.24.dist-info}/top_level.txt +0 -0
|
@@ -154,7 +154,7 @@ class LateFusionModel(BaseModel):
|
|
|
154
154
|
|
|
155
155
|
if self.include_sat:
|
|
156
156
|
# Param checks
|
|
157
|
-
assert sat_history_minutes is not None
|
|
157
|
+
assert sat_history_minutes is not None, "sat_history_minutes is not present in config"
|
|
158
158
|
|
|
159
159
|
self.sat_sequence_len = (
|
|
160
160
|
sat_history_minutes - min_sat_delay_minutes
|
|
@@ -174,12 +174,18 @@ class LateFusionModel(BaseModel):
|
|
|
174
174
|
|
|
175
175
|
if self.include_nwp:
|
|
176
176
|
# Param checks
|
|
177
|
-
assert nwp_forecast_minutes is not None
|
|
178
|
-
assert nwp_history_minutes is not None
|
|
177
|
+
assert nwp_forecast_minutes is not None, "nwp_forecast_minutes is not present in config"
|
|
178
|
+
assert nwp_history_minutes is not None, "nwp_history_minutes is not present in config"
|
|
179
179
|
|
|
180
180
|
# For each NWP encoder the forecast and history minutes must be set
|
|
181
|
-
assert set(nwp_encoders_dict.keys()) == set(nwp_forecast_minutes.keys())
|
|
182
|
-
|
|
181
|
+
assert set(nwp_encoders_dict.keys()) == set(nwp_forecast_minutes.keys()), (
|
|
182
|
+
f"nwp encoder keys {set(nwp_encoders_dict.keys())} do not match "
|
|
183
|
+
f"nwp_forecast_minutes keys {set(nwp_forecast_minutes.keys())}"
|
|
184
|
+
)
|
|
185
|
+
assert set(nwp_encoders_dict.keys()) == set(nwp_history_minutes.keys()), (
|
|
186
|
+
f"nwp encoder keys {set(nwp_encoders_dict.keys())} do not match "
|
|
187
|
+
f"nwp_history_minutes keys {set(nwp_history_minutes.keys())}"
|
|
188
|
+
)
|
|
183
189
|
|
|
184
190
|
if nwp_interval_minutes is None:
|
|
185
191
|
nwp_interval_minutes = dict.fromkeys(nwp_encoders_dict.keys(), 60)
|
|
@@ -213,7 +219,7 @@ class LateFusionModel(BaseModel):
|
|
|
213
219
|
fusion_input_features += self.nwp_encoders_dict[nwp_source].out_features
|
|
214
220
|
|
|
215
221
|
if self.include_pv:
|
|
216
|
-
assert pv_history_minutes is not None
|
|
222
|
+
assert pv_history_minutes is not None, "pv_history_minutes is not present in config"
|
|
217
223
|
|
|
218
224
|
self.pv_encoder = pv_encoder(
|
|
219
225
|
sequence_length=pv_history_minutes // pv_interval_minutes + 1,
|
|
@@ -152,13 +152,13 @@ class PVNetLightningModule(pl.LightningModule):
|
|
|
152
152
|
def _store_val_predictions(self, batch: TensorBatch, y_hat: torch.Tensor) -> None:
|
|
153
153
|
"""Internally store the validation predictions"""
|
|
154
154
|
|
|
155
|
-
|
|
155
|
+
target_key = self.model._target_key
|
|
156
156
|
|
|
157
|
-
y = batch[
|
|
157
|
+
y = batch[target_key][:, -self.model.forecast_len :].cpu().numpy()
|
|
158
158
|
y_hat = y_hat.cpu().numpy()
|
|
159
|
-
ids = batch[f"{
|
|
159
|
+
ids = batch[f"{target_key}_id"].cpu().numpy()
|
|
160
160
|
init_times_utc = pd.to_datetime(
|
|
161
|
-
batch[f"{
|
|
161
|
+
batch[f"{target_key}_time_utc"][:, self.model.history_len+1]
|
|
162
162
|
.cpu().numpy().astype("datetime64[ns]")
|
|
163
163
|
)
|
|
164
164
|
|
|
@@ -11,7 +11,7 @@ pvnet/models/base_model.py,sha256=CnQaaf2kAdOcXqo1319nWa120mHfLQiwOQ639m4OzPk,16
|
|
|
11
11
|
pvnet/models/ensemble.py,sha256=1mFUEsl33kWcLL5d7zfDm9ypWxgAxBHgBiJLt0vwTeg,2363
|
|
12
12
|
pvnet/models/late_fusion/__init__.py,sha256=Jf0B-E0_5IvSBFoj1wvnPtwYDxs4pRIFm5qHv--Bbps,26
|
|
13
13
|
pvnet/models/late_fusion/basic_blocks.py,sha256=_cYGVyAIyEJS4wd-DEAXQXu0br66guZJn3ugoebWqZ0,1479
|
|
14
|
-
pvnet/models/late_fusion/late_fusion.py,sha256=
|
|
14
|
+
pvnet/models/late_fusion/late_fusion.py,sha256=7uQPo_OlNXrJOE9nYHTEvwJx2POKg4drJfdnPxwiaJU,16283
|
|
15
15
|
pvnet/models/late_fusion/encoders/__init__.py,sha256=bLBQdnCeLYhwISW0t88ZZBz-ebS94m7ZwBcsofWMHR4,51
|
|
16
16
|
pvnet/models/late_fusion/encoders/basic_blocks.py,sha256=DGkFFIZv4S4FLTaAIOrAngAFBpgZQHfkGM4dzezZLk4,3044
|
|
17
17
|
pvnet/models/late_fusion/encoders/encoders3d.py,sha256=9fmqVHO73F-jN62w065cgEQI_icNFC2nQH6ZEGvTHxU,7116
|
|
@@ -22,11 +22,11 @@ pvnet/models/late_fusion/site_encoders/__init__.py,sha256=QoUiiWWFf12vEpdkw0gO4T
|
|
|
22
22
|
pvnet/models/late_fusion/site_encoders/basic_blocks.py,sha256=iEB_N7ZL5HMQ1hZM6H32A71GCwP7YbErUx0oQF21PQM,1042
|
|
23
23
|
pvnet/models/late_fusion/site_encoders/encoders.py,sha256=k4z690cfcP6J4pm2KtDujHN-W3uOl7QY0WvBIu1tM8c,11703
|
|
24
24
|
pvnet/training/__init__.py,sha256=FKxmPZ59Vuj5_mXomN4saJ3En5M-aDMxSs6OttTQOcg,49
|
|
25
|
-
pvnet/training/lightning_module.py,sha256=
|
|
25
|
+
pvnet/training/lightning_module.py,sha256=RFp0kOmRW0cYU__i7SRCJUIvlp57s5cZ_H3hy2JnBxE,12954
|
|
26
26
|
pvnet/training/plots.py,sha256=4xID7TBA4IazaARaCN5AoG5fFPJF1wIprn0y6I0C31c,2469
|
|
27
27
|
pvnet/training/train.py,sha256=1tDA34ianCRfilS0yEeIpR9nsQWaJiiZfTD2qRUmgEc,5214
|
|
28
|
-
pvnet-5.0.
|
|
29
|
-
pvnet-5.0.
|
|
30
|
-
pvnet-5.0.
|
|
31
|
-
pvnet-5.0.
|
|
32
|
-
pvnet-5.0.
|
|
28
|
+
pvnet-5.0.24.dist-info/licenses/LICENSE,sha256=tKUnlSmcLBWMJWkHx3UjZGdrjs9LidGwLo0jsBUBAwU,1077
|
|
29
|
+
pvnet-5.0.24.dist-info/METADATA,sha256=z5HMQ9aNzK8j1Wz1wdHRHyA91_bIzQ2bkPepLLuFEGM,16371
|
|
30
|
+
pvnet-5.0.24.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
31
|
+
pvnet-5.0.24.dist-info/top_level.txt,sha256=4mg6WjeW05SR7pg3-Q4JRE2yAoutHYpspOsiUzYVNv0,6
|
|
32
|
+
pvnet-5.0.24.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|