-
Notifications
You must be signed in to change notification settings - Fork 14
Feature/add spatial rmse #68
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
base: main
Are you sure you want to change the base?
Conversation
bd66376 to
2d51778
Compare
* Added flexibility for more variables. Added normalization statistics from graphcast as json files, refactored metrics, datasets and tests as well as lightning modules. The latter have to account for nans in the data when including sea-ice-fraction and others * Added code to zero out NaNs in ground truth values for loss calculation * Renamed stats to norm, changed variable output for label wrapper, applied changes to configs * Removed import that causes error * Replaced norm scheme in graphcast statsconfig * Fixed bug in load_module due to missing stats_cfg and changed behaviour of to_xarray routines to account for levels * Added softlinks recommended by geoarches doc to .gitignore and removed pushed softlinks * Addressed issues with paramaters interpolate_nans and warning_on_nans * Added tensordict utility to test predictions for NaNs * Added documentation to the normalization module, changed name of norm file and norm module according to reviews, adapted norm files * Changes loss_coffs to compute_loss_coeffs_args for clarity, added test for graphcast stats * Added dimension names of the dataset as arguments for the dataloaders, added comment to test of era5 loaders with graphcast norm scheme * Fixed Bug in dcpp test due to missing dimension names * Added more flexibility for data naming (either names have leading zeros or not) * Refactored code to use dimension indexers for selecting dimensions and converting between tensordict and xarray, modified tests * Fixed bug with multistep rollout due to missing next-states, added torch.int64 to allow dates after 2038 * Changed behaviour of dimension indexers, added description, adapted eval_multistep and test files * fixed format problems --------- Co-authored-by: Renu Singh <[email protected]>
2d51778 to
3255e23
Compare
8fd6795 to
c326000
Compare
c326000 to
49f4b02
Compare
dcee04d to
f1a69a1
Compare
f1a69a1 to
fce4efa
Compare
| cmap="plasma", | ||
| origin="upper", | ||
| extent=[-180, 180, -90, 90], | ||
| transform=ccrs.PlateCarree(), |
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.
Robinson gives the curved projection, but matter of taste
|
|
||
| spatial_datas = [] | ||
| for base_dir in base_dirs: | ||
| spatial_data = torch.load( |
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.
To be consistent, I would argue that deciding for a storage format, e.g. netcdf, seems desirable to me.
robert-DL
left a comment
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.
Just minor comments. If we agree on the changes, we can do them in a separate merge request
| fig = plt.figure(figsize=(4, 2)) | ||
| num_plots = len(spatial_datas) | ||
| fig, axes = plt.subplots( | ||
| 1, num_plots, figsize=(6 * num_plots, 5), subplot_kw={"projection": ccrs.PlateCarree()} |
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.
I think single plots are better, one can align them later in latex files
add spatial_mse to DeterministicMetrics:
eval_multistep.py supports