Skip to content

Checkpoint Format Update - #617

Open
feathern wants to merge 27 commits into
geodynamics:mainfrom
feathern:res_change
Open

Checkpoint Format Update#617
feathern wants to merge 27 commits into
geodynamics:mainfrom
feathern:res_change

Conversation

@feathern

@feathern feathern commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

This PR is ready for review, but please don't merge yet -- I would like to run a few more tests while it is being reviewed.

This PR updates the format of the checkpoint files so that the Adams-Bashforth terms are stored in terms of Chebyshev coefficients instead of on the physical-space radial grid. This is the same format as that already used for the state vector fields (W,P,S,Z,C,A).

A side effect of this change is that the radial resolution can now be degraded, if desired, on restart. This was previously not supported.

Included in this PR:

  1. The checkpoint_version variable has been updated from 2 to 3.

  2. Compatibility for reading version=2 checkpoints has been retained.

  3. Rayleigh now allows the user to degrade the resolution of a version=3 checkpoint. If this is attempted for a version=2 checkpoint, Rayleigh exits and prints an error message that also provides instructions to the user describing how to convert to version=3 so that radial resolution can be degraded. This feature is not yet supported for multi-domain models.

  4. Compatibility with multi-domain checkpoints is otherwise retained.

  5. I had to make a small change to Fields.F90 that crept in when the compressible branch was initially merged. Without it, n_active_scalars and n_passive_scalars were getting counted twice when setting the buffer size for wsp%p1b, which holds the Adams Bashforth terms and is needed for checkpointing.

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.

1 participant