Skip to content
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

Update ocean grid inputs to mosaic format #23

Open
dougiesquire opened this issue Jun 25, 2024 · 8 comments
Open

Update ocean grid inputs to mosaic format #23

dougiesquire opened this issue Jun 25, 2024 · 8 comments

Comments

@dougiesquire
Copy link

dougiesquire commented Jun 25, 2024

These configurations use an old FMS format to specify the ocean grid. Can/should we update to use the new mosaic format? Can we just use the mosaic from the ACCESS-OM2 1 deg configurations?

This notebook includes some checks to help us answer these questions.

To summarise:

  • The ACCESS-ESM1.5 and ACCESS-OM2 grid locations are the same, but the cell areas are different.
  • The differences in the cell areas are small and at the north pole
  • It looks like the differences in area are introduced by the FRE-NCTools tool used to update to the mosaic format, transfer_to_mosaic_grid. Converting the ESM1.5 grid to the mosaic format using transfer_to_mosaic_grid gives areas that match OM2.

So, we could update the ocean grid to use the same file as the OM2 1 deg configuration, but this will change cell areas slightly which will presumably change results. Does this mean we should leave this for a subsequent release?

@anton-seaice
Copy link

anton-seaice commented Jun 25, 2024

It looks like the ESM1.5 ice + ocean grids are consistent with each other, so that's good? Whats the advantage in the new format?

(EDIT: we should be able to get 1e-13 accuracy between ice & ocn grids by regenerating)

@dougiesquire
Copy link
Author

It seems that calculating the areas near a pole is... complex. See

@anton-seaice
Copy link

It looks like a fix was made in FRE-NCtools.

Does one of the versions of the grids have an obvious jump / discontinuity in areas around the true north pole?

@dougiesquire
Copy link
Author

It looks like a fix NOAA-GFDL/FRE-NCtools#60 in FRE-NCtools.

I built FRE-NCTools from source yesterday (i.e. including that bug fix) and converted the ESM1.5 grid to a mosaic spec that had areas that match the OM2 grid. So that fix doesn't resolve our issue.

Both the ESM1.5 and OM2 grid areas have a small jump across the north pole, but it's slightly smaller in the OM2 grid...? See the notebook above for details.

Screenshot 2024-06-26 at 12 41 11 PM

@ezhilsabareesh8
Copy link

ezhilsabareesh8 commented Jun 27, 2024

This plot shows the area of OM2 grid (orig) and the newly generated (new) using make_hgrid grid at the north pole along the longitude direction. The left plot shows the area symmetry error.

plt.plot(Orig05['area'][-1,:], label='orig' )

Screenshot 2024-06-27 at 12 18 08 pm

A big spike at the tripoles shows the abnormalities in cell area in the existing OM2 grid and new grid. I tried generating the grid using --rotate_poly, which calculates the area of polygons near the pole using a copy of the polygon that has been rotated away from the pole. It resolves the abnormal area spike however it Introduces a big area symmetry error compared to the original one without --rotate_poly (left plot). Even though the error is of the magnitude of ~2e-6% (3m2 error on ~1.5e8 m2) still it we need to think about what can be done, @ofa001 and @DaveBi any thoughts on this?

Screenshot 2024-06-27 at 12 31 27 pm

PS - Area symmetry error is calculated at the north pole as following:

plt.plot( New05['area'][-1,:] - New05['area'][-1,::-1], label='new' );
plt.plot( Orig05['area'][-1,:] - Orig05['area'][-1,::-1], label='orig' );

@dougiesquire
Copy link
Author

Note, --rotate-poly is not an option for transfer_to_mosaic_grid but I modified FRE-NCtools to add it. As @ezhilsabareesh8 shows using make_hgrid, this gets rid of the spike at the pole. See the notebook linked in my first post for details.

Good catch re the increase in symmetry errors @ezhilsabareesh8.

@aidanheerdegen
Copy link
Member

Great work @ACCESS-NRI/ocean!

So is there a recommendation for how to proceed?

@dougiesquire
Copy link
Author

dougiesquire commented Jul 30, 2024

So is there a recommendation for how to proceed?

We are unable to reproduce the old grid exactly to correct the issue at the pole. So I think we should release ESM1.5 with the original "pre-mosaic" grid and then update all the ice and ocean grids (and related files) for a subsequent major release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants