-
-
Notifications
You must be signed in to change notification settings - Fork 5
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
Issue/solar night time #130
Conversation
# filter out night time | ||
if self.asset_type == SiteAssetType.pv: | ||
if self.asset_type == SiteAssetType.pv.name: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is the main bit of code
for idx in range(8): | ||
values_df["forecast_power_kw"][idx] -= ( | ||
values_df["forecast_power_kw"][idx] - final_gen_points | ||
) * smooth_values[final_gen_index + idx] | ||
log.debug(f"New values are {values_df['forecast_power_kw']}") | ||
|
||
if self.asset_type == "solar": |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This didnt do anything due to above if loop
@@ -167,7 +172,8 @@ def set_night_time_zeros(batch, preds, sun_elevation_limit=0.0): | |||
sun_elevation = sun_elevation.detach().cpu().numpy() | |||
|
|||
# expand dimension from (1,197) to (1,197,7), 7 is due to the number plevels | |||
sun_elevation = np.repeat(sun_elevation[:, :, np.newaxis], 7, axis=2) | |||
n_plevels = preds.shape[2] | |||
sun_elevation = np.repeat(sun_elevation[:, :, np.newaxis], n_plevels, axis=2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is the only other relevant change
Pull Request
Description
fix for making sure soalr forcast are zero at night time
There was a bug, Need to change
self.asset_type == SiteAssetType.pv:
toself.asset_type == SiteAssetType.pv.name:
#129
How Has This Been Tested?
CI tests
Checklist: