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

Improve Soca2Cice (use icepack to cleanup after rescaling) #1111

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

shlyaeva
Copy link
Contributor

@shlyaeva shlyaeva commented Dec 27, 2024

Description

There are several improvements to Soca2Cice here:

  • use icepack's cleanup_itd after rescaling to rebin thickness categories if necessary, remove very small ice areas and remove snow if snow enthalpy indicates out-of-bounds temperatures (see details in cleanup_itd).
    Notes:
    • Ice thickness categories are set up automatically by icepack_init_itd. I am not sure this is always the correct way to set up ice categories; does anyone know? It's important for rebinning.
    • I have removed the existing adjustment of snow enthalpy from the code since I expect it's now covered (in a different way) by cleanup_itd.
    • The rebinning uses the model's time step. I added a new yaml option icepack time step with pseudorandom default 300.
    • If cleanup_itd indicates that icepack aborted, the code will abort. This can be replaced (or optionally replaced) by shuffling if the cleanup_itd aborts.
    • Only ice/snow temperature, ice and snow enthalpies and ice salinity are currently updated in the cleanup_itd, but I can add more tracers (e.g. melt ponds?)
  • exclude backgrounds that are equal to sea ice edge value from rescaling. Previously the code both shuffled and rescaled where background == sea ice edge. This fix is mostly to cover an edge case when sea ice edge is set to zero. In this case, when the background is zero, we definitely don't want to rescale (i.e. divide by zero)
  • explicitly cover zero analysis ice concentration case. I think this was not covered before (cleanup_ice on develop covers the case where the restart fields updated after shuffling and rescaling are zero, but doesn't cover the case where they should have been updated to zero).
    Note: I kept Guillaume's update to the ice/snow temperature as icepack's liquidus_temperature_mush.
  • add shuffle stencil size as a yaml option (default is 9) to add some flexibility for testing
  • removed some unused variables.

Issue(s) addressed

fixes #993 in a roundabout way (instead of adding the fixes suggested here, cleanup_itd is used to do that and more)

Testing

Tested on orion with gnu and unit tests, the current test mostly rebins categories up and down, and zaps small areas on a few occasions.

Tested on hera with intel with high res gdas 3DVar experiment, setting ice edge to 0.15 and running a few cycles. cleanup_itd mostly rebins categories and zaps snow with low snow volumes and zero snow enthalpies.

Copy link
Contributor

@guillaumevernieres guillaumevernieres left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks @shlyaeva .

fiso_ocn=fiso_ocn)
call icepack_warnings_flush(6)
if (icepack_warnings_aborted()) then
call abor1_ftn("Soca2Cice: icepack aborted during cleanup_itd")
Copy link
Contributor

Choose a reason for hiding this comment

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

I suspect this conditional is going to be a "rare event"? Or have you seen failures already at that stage? Is this where you are planning to shuffle in the future?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I haven't seen this fail on this condition yet, so hoping it is a rare event. Yes, I think that's where it would make sense to do shuffle!

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

Successfully merging this pull request may close these issues.

More engineering fixes required for the CICE initialization
2 participants