Refactoring climpred to use classes under the hood
See original GitHub issueMany of the function signatures are the same; it might be good to use class inheritance to solve that.
Here’s an outline:
Comparisons():
__init__:
forecasts
references
Alignment(Comparisons):
__init__:
alignment
Scoring(Alignment):
__init__:
metrics
comparisons
dimensions
HindcastScoring(Scoring):
function
self.forecasts
self.references
self.alignment
self.metrics
self.comparisons
self.dimensions
PersistenceScoring(Scoring):
function
self.forecasts
self.references
self.alignment
self.metrics
self.comparisons
self.dimensions
UninitializedScoring(Scoring):
function
self.forecasts
self.references
self.alignment
self.metrics
self.comparisons
self.dimensions
Bootstrap(Scoring):
__init__:
resample_dimemsion
significance_level
PerfectModelBootstrap(Bootstrap):
function
self.forecasts
self.references
self.alignment
self.metrics
self.comparisons
self.dimensions
self.resample_dimension
self.significance_level
HindcastBootstrap(Bootstrap):
function
self.forecasts
self.references
self.alignment
self.metrics
self.comparisons
self.dimensions
self.resample_dimension
self.significance_level
Items under __init__
are the necessary keyword arguments to inherit from that class, items under function
are inherited arguments. Feel free to question/comment/suggest!
Issue Analytics
- State:
- Created 4 years ago
- Comments:6
Top Results From Across the Web
climpred
PerfectModelEnsemble and HindcastEnsemble classes to make ... can be called directly in climpred, we suggest that you use our classes ( ...
Read more >climpred: verification of weather and climate forecasts ...
In our past coding journey, collaborative coding, feedbacking issues and pull requests advanced our code and thinking about forecast verification more than we ......
Read more >climpred: verification of weather and climate forecasts
In our past coding journey, collaborative coding, feedbacking issues and pull requests advanced our code and thinking about forecast verification more than we ......
Read more >Reference Forecasts — climpred documentation
In climpred , we use uninitialized ensembles as a baseline for how important (reoccurring) initializations are for lending predictability to ...
Read more >Verification Alignment — climpred documentation
"same_inits" : Use a common set of initializations that verify across all leads. This ensures that there is no bias in the result...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
for discussion about API in with bootstrapping see #375
Still continuing on this front. We’ve prioritized getting the JOSS paper submitted with the current version. I’m also reviewing and patching ideas on
xskillscore
andclimpred
, which is pulling from my time on this problem. I’d sayclimpred_skeleton
is about 2/3rds of the way there. Then the project of revamping this code is big. Will likely create a branch called e.g.classify_climpred
and then do little edits to that as I build up the code base so it is easily reviewable.