-
Couldn't load subscription status.
- Fork 7
Issue/217 data source configs #255
Conversation
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 looking really good! Thank you!
And a really nice and elegant implementation of the default_history_minutes thing, too!
One way in which this change could make our code considerably simpler is if the names of the config fields precisely align with the argument names in the DataSource constructor.
So, for example, in the config model, we could change nwp_channels and satellite_channels to just channels. Or, alternatively, we could change the DataSource subclasses... specifically, we could change SatDataSource and NWPDataSource to take the arguments satellite_channels and nwp_channels. (I'd probably slightly lean towards the second option, because I like the verbose and explicit field names that you've chosen for the config fields! Although I'm very happy to be persuaded otherwise! Changing the DataSource sub-class constructor arguments could be a subsequent PR, though 🙂 )
Thanks again!
| forecast_minutes=config.input_data.default_forecast_minutes, #: Number of minutes of forecast. | ||
| satellite_image_size_pixels=config.input_data.satellite.satellite_image_size_pixels, | ||
| nwp_image_size_pixels=config.input_data.nwp.nwp_image_size_pixels, | ||
| nwp_channels=NWP_VARIABLE_NAMES, |
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.
The value of these consts also needs changing near the top of this file, I think?
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.
Yes, they do - thank you
Yea I would vote to keep the variables verbose, and change the Thanks for your comments |
PR comments from Jack - thanks Co-authored-by: Jack Kelly <jack@OpenClimateFix.org>
Sounds good to me! Thanks! |
Pull Request
Description
Warning this is a break change for the confiiguration model
Fixes #217
How Has This Been Tested?
Unittest
ran prepare_ml_data.py script dummy run, ot check it works
No
Yes
Checklist: