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

Add smoothing to remapping of SSS restoring #883

Merged
merged 2 commits into from
Jan 14, 2025

Conversation

xylar
Copy link
Collaborator

@xylar xylar commented Jan 13, 2025

This requires a major reorganization of the step to be more like remap_topography after its recent reorganization.

Remapping is performed with mbtempest. The public function remap_sss() has been removed. (It was not mentioned in the docs.)

This merge also adds a remapping step to the utility that generates the SSS field from WOA23. The data is remapped to a cubed-sphere grid at ne300 (~10 km) resolution. Remapping from the cubed sphere to MPAS meshes will be much more performant than remapping from the WOA original lat-lon grid, particularly when there is smoothing near the poles as we do here.

The smoothing goes linearly from zero at 70 N to 1000 km at 90 N.

Checklist

  • User's Guide has been updated
  • Developer's Guide has been updated
  • Documentation has been built locally and changes look as expected
  • Document (in a comment titled Testing in this PR) any testing that was used to verify the changes

@xylar xylar added enhancement New feature or request ocean in progress This PR is not ready for review or merging labels Jan 13, 2025
@xylar xylar requested a review from vanroekel January 13, 2025 14:25
@xylar xylar self-assigned this Jan 13, 2025
This merge also includes some other minor clean-up and reorganization.

The documentation is also updated and cleaned up to reflect these
changes.
@xylar xylar force-pushed the smooth-salinity-restoring branch from a5fdaa6 to 4a457cd Compare January 14, 2025 13:22
@xylar xylar removed the in progress This PR is not ready for review or merging label Jan 14, 2025
This requires a major reorganization of the step to be more
like `remap_topography` after its recent reorganization.

Remapping is performed with `mbtempest`.  The public function
`remap_sss()` has been removed.  (It was not mentioned in the docs.)
@xylar xylar force-pushed the smooth-salinity-restoring branch from 4a457cd to a677010 Compare January 14, 2025 13:25
@xylar xylar marked this pull request as ready for review January 14, 2025 13:25
@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

Testing

I ran the remap_sea_surface_salinity step for the IcoswISC30E3r5 mesh. The step took about 3 minutes on 4 Chrysalis nodes (without using the cubed-sphere grid it had not completed after 30 minutes). With a maximum smoothing length scale of 1000 km (the current default), the result is this field:

sss_jan_with_smoothing

Compare with a similar plot without smoothing:

image

Results are in:

/lcrc/group/e3sm/ac.xylar/compass_1.7/chrysalis/test_20250114/icosr5_sss_restoring/ocean/global_ocean/files_for_e3sm/remap_sea_surface_salinity_restoring

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

Here is what the smoothing field looks like:
expand_dist

The units are meters.

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

@vanroekel, this is now ready for your review. Feel free to review the code (by inspection) but the main review I would like is whether you are good with the outcome.

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

@maltrud, @milenaveneziani, @alicebarthel and @irenavankova, you all commented on #872 so I wanted to make sure you're aware of this follow-up work.

@milenaveneziani
Copy link

It looks good to me @xylar, thanks for working on this.
If we wanted, could we apply this tool to smooth the WOA data that we use in MPAS-Analysis? This would eliminate the weird patching that we usually see in the bias plot.

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

If we wanted, could we apply this tool to smooth the WOA data that we use in MPAS-Analysis? This would eliminate the weird patching that we usually see in the bias plot.

It's something we could think about. It relies on conservative remapping with MOAB and that performs really badly with latitude-longitude grids (because there are so many tiny, overlapping cells near the poles). I had to switch to putting the SSS fields on a cubed-sphere grid here to make the remapping/smoothing to the MPAS mesh performant. I'm not sure how feasible it is to take a similar approach in MPAS-Analysis.

@milenaveneziani
Copy link

I see. Thanks for clarifying that part, I had missed it.

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

I had missed it.

I see I forgot to add that to the PR description! My mistake. It's there now.

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

If we wanted, could we apply this tool to smooth the WOA data that we use in MPAS-Analysis? This would eliminate the weird patching that we usually see in the bias plot.

Thinking about this further, I would feel weird about smoothing an "observational" dataset presented in MPAS-Analysis. I think it would be more honest to just mask out the parts we don't trust than to manipulate them.

Copy link
Collaborator

@vanroekel vanroekel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving by visual inspection of code and examination of resulting smoothed field.

Thanks @xylar this looks great to me

@xylar
Copy link
Collaborator Author

xylar commented Jan 14, 2025

Thanks @vanroekel!

@xylar xylar merged commit 9accc96 into MPAS-Dev:main Jan 14, 2025
6 checks passed
@xylar xylar deleted the smooth-salinity-restoring branch January 14, 2025 16:27
@alicebarthel
Copy link
Contributor

Thanks @xylar , this looks great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ocean
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants