Image flags in restart files

Dear all,

In recent versions of lammps (30Oct2013) it appears that the image flags of atoms are not correctly written to restart files. I noticed this when lammps gave the "Inconsistent image flags" warning when reading a restart with bonded atoms. Inspecting the dump file (generated after read_restart) I found that all of the image flags for all atoms were -512.

I reproduced this problem using a minimal lammps script (attached) where a single atom of type atomic diffuses in a periodic box using fix nve and fix langevin. In the generated restart file the images flags are -512. This can be seen both in a dump file generated after reading the restart, and in a data file generated using the restart2data.cpp tool.

I ran the same script using an older version of lammps (21Feb13) and the image flags were correct after the restart. Is this a bug in recent versions, or am I doing something wrong?

Chris Brackley

in.script (904 Bytes)

I’m not reproducing this. When I run your script (thanks for posting
a simple script), the image flags after the restart are all 0 or -1.

I’m running the current 7Nov13 version.

In all 3 cases, it appears to be good:

in the restart file (viewed after running restart2data to convert to data file)

in the 2nd dump file (produced by your script)
in a data file written by the write_data command (added to your

script after the write_restart command).

Are you compiling with any of these flags set?


SMALLBIG is default, BIGBIG will change the size of the image flag storage,

and you would have to re-compile restart2data.cpp with the same
setting if you changed it.