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

Fix InputOutput when enable_bubble is true #1999

Merged
merged 1 commit into from
Sep 19, 2024
Merged

Conversation

Sbozzolo
Copy link
Member

It turns out that we were not saving and restoring a piece of information that is required to fully reconstruct a 2DSpectralSpace: the bubble correction.

When enabled, the bubble correction recomputes the Jacobian to improve their accuracy. InputOutput was not saving this piece of information into the HDF5 file, so spaces read from file always assumed that it was false. This led to discrepancies in the space, and these discrepancies led to problems in the evolution.

Interestingly, for the low-resolution cases we consider in the Atmos CI, enable_bubble has very small effects on the value of the Jacobian, with a relative difference compared to the case without bubble smaller than the floating point precision for Float32. In spite of this, it affected the evolution in more noticeable way, in particular in vectors and with hyperdiffusion.

Now, bubble is saved as attribute so that it can be read back.

This commit also bumps the version of ClimaCore to 0.14.6

It turns out that we were not saving and restoring a piece of
information that is required to fully reconstruct a `2DSpectralSpace`:
the bubble correction.

When enabled, the bubble correction recomputes the Jacobian to improve
their accuracy. `InputOutput` was not saving this piece of information
into the HDF5 file, so spaces read from file always assumed that it was
false. This led to discrepancies in the space, and these discrepancies
led to problems in the evolution.

Interestingly, for the low-resolution cases we consider in the Atmos CI,
`enable_bubble` has very small effects on the value of the Jacobian,
with a relative difference compared to the case without bubble smaller
than the floating point precision for Float32. In spite of this, it
affected the evolution in more noticeable way, in particular in vectors
and with hyperdiffusion.

Now, `bubble` is saved as attribute so that it can be read back.

This commit also bumps the version of ClimaCore to 0.14.6
Copy link
Member

@charleskawczynski charleskawczynski left a comment

Choose a reason for hiding this comment

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

Good catch, thanks for fixing this!

@charleskawczynski charleskawczynski merged commit bd20629 into main Sep 19, 2024
22 of 23 checks passed
@charleskawczynski charleskawczynski deleted the gb/fix_bubble branch September 19, 2024 12:34
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.

2 participants