AMReX-Astro / Castro

Castro (Compressible Astrophysics): An adaptive mesh, astrophysical compressible (radiation-, magneto-) hydrodynamics simulation code for massively parallel CPU and GPU architectures.
http://amrex-astro.github.io/Castro
Other
293 stars 99 forks source link

chk files are not compatible between different compiler systems. #2849

Closed aisclark91 closed 1 month ago

aisclark91 commented 1 month ago

It seems that chk files obtained from executables compiled differently cannot be reused. To solve this issue a way to convert between plt files and chk files should be addressed based on the source and destination executables.

For example, if we use the gnu compiler executable Castro2d.gnu.MPI.CUDA to create the chk backup files and we plan to use another executable, let's say Castro2d.cray.MPI.CUDA.ex to read those chk files I get:

Lmod is automatically replacing "nvhpc/23.9" with "gcc-native/12.3".

Lmod is automatically replacing "PrgEnv-nvhpc/8.5.0" with "PrgEnv-gnu/8.5.0".

Due to MODULEPATH changes, the following have been reloaded:
  1) cray-mpich/8.1.28

amrex::Error::0::Checkpoint format incompatible with current code !!!
SIGABRT
zingale commented 1 month ago

the issue here is different checkpoint versions. Each time a change is made to the checkpoint format (e.g. adding a field), we increment the checkpoint version. In this case, the version was updated in June 2023 because of a radiation change and these checkpoint files were produced in April 2023.