Restart Capability - mlwong/HAMeRS GitHub Wiki

To restart a simulation, you need to provide restart directory and restore number in addition to the input file:

<location of main> <input filename> <restart dir> <restore number>

The simulation can only be restarted with the same number of processors from the previous run. To restart the simulation with different number of processors, you can use the restart-redistribute tool from SAMRAI. The tool can be built with other optional tools during the build process of SAMRAI using:

gmake tools

The restart-redistribute tool from SAMRAI is a parallel tool. It is parallelized on the smaller of the number of input files (original number of processors) and the number of output files (new desired number of processors). Therefore, you may run on any number of processors up to, but not greater than, this number. Running parallel programs is platform dependent. The following example showing the usage of the restart-redistribute tool assumes the use of mpirun to launch parallel programs:

mpirun -np N restart-redistribute INPUT-DIR OUTPUT-DIR TIMESTEP NUM_PROCS_OUT

where INPUT-DIR is the directory containing the restart dumps from a previous run, OUTPUT-DIR is the name of the directory to contain new restart files, TIMESTEP is the integer identifier of the timestep of the restart dumps and NUM_PROCS_OUT is the new desired number of processors.