aditya-grover / climate-learn

Source code for ClimateLearn
MIT License
310 stars 49 forks source link

Climatology bug fixed in shard dataset #95

Closed prakhar6sharma closed 1 year ago

prakhar6sharma commented 1 year ago

There was a bug in the shard_dataset.py where self.climatology is set to mean_out_data(See this).

mean_out_data here is the mean over the entire data across all longitudes and latitudes whereas the climatology definition says that mean should be taken over all data points for a given longitude and latitude.

I can confirm that this bug was not there in map_dataset.py. (See this).

I have implemented the climatology calculation for ShardDataset now and tested locally that for the same configuration both MapDataset and ShardDataset have same climatology baseline numbers.