From 9e5b419e4eeb4c194e1fe25f92fe7dbdbc44f826 Mon Sep 17 00:00:00 2001 From: Stan Moore Date: Fri, 16 Dec 2022 08:33:26 -0700 Subject: [PATCH 1/5] Fix bug when atoms are added after run --- src/read_data.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/read_data.cpp b/src/read_data.cpp index 9d9d7139a5..7cb1209ed1 100644 --- a/src/read_data.cpp +++ b/src/read_data.cpp @@ -375,6 +375,14 @@ void ReadData::command(int narg, char **arg) if (addflag == NONE) { domain->box_exist = 1; update->ntimestep = 0; + } else { + + // clear ghost count and any ghost bonus data internal to AtomVec + // same logic as beginning of Comm::exchange() + // do it now b/c creating atoms will overwrite ghost atoms + + atom->nghost = 0; + atom->avec->clear_bonus(); } // compute atomID and optionally moleculeID offset for addflag = APPEND From 85ac3ac98ba4c3c5be607399379e6811897e9768 Mon Sep 17 00:00:00 2001 From: Stan Moore Date: Fri, 16 Dec 2022 09:42:06 -0700 Subject: [PATCH 2/5] Also need to clear atom map --- src/create_atoms.cpp | 2 ++ src/read_data.cpp | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/create_atoms.cpp b/src/create_atoms.cpp index 9c66d1d19b..f070d0a53f 100644 --- a/src/create_atoms.cpp +++ b/src/create_atoms.cpp @@ -441,10 +441,12 @@ void CreateAtoms::command(int narg, char **arg) MPI_Barrier(world); double time1 = platform::walltime(); + // clear global->local map for owned and ghost atoms // clear ghost count and any ghost bonus data internal to AtomVec // same logic as beginning of Comm::exchange() // do it now b/c creating atoms will overwrite ghost atoms + if (atom->map_style != Atom::MAP_NONE) atom->map_clear(); atom->nghost = 0; atom->avec->clear_bonus(); diff --git a/src/read_data.cpp b/src/read_data.cpp index 7cb1209ed1..757954ff0e 100644 --- a/src/read_data.cpp +++ b/src/read_data.cpp @@ -377,10 +377,12 @@ void ReadData::command(int narg, char **arg) update->ntimestep = 0; } else { + // clear global->local map for owned and ghost atoms // clear ghost count and any ghost bonus data internal to AtomVec // same logic as beginning of Comm::exchange() - // do it now b/c creating atoms will overwrite ghost atoms + // do it now b/c adding atoms will overwrite ghost atoms + if (atom->map_style != Atom::MAP_NONE) atom->map_clear(); atom->nghost = 0; atom->avec->clear_bonus(); } From 0b7a55dac620a7eff13d7b37d7180a0a549f333b Mon Sep 17 00:00:00 2001 From: Steve Plimpton Date: Thu, 22 Dec 2022 08:11:22 -0700 Subject: [PATCH 3/5] OVITO info in dump doc page --- doc/src/dump.rst | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/doc/src/dump.rst b/doc/src/dump.rst index 4b60a9705e..7242b3d855 100644 --- a/doc/src/dump.rst +++ b/doc/src/dump.rst @@ -254,9 +254,12 @@ Note that *atom*, *custom*, *dcd*, *xtc*, and *xyz* style dump files can be read directly by `VMD `_, a popular tool for viewing molecular system. -Likewise the `OVITO visualization tool `_, -popular for materials modeling, can read the *atom*, *custom*, and -*grid* style dump files. +Likewise the `OVITO visualization package `_, +popular for materials modeling, can read the *atom*, *custom*, +*local*, *xtc*, *cfg*, *netcdf*, and *xyz* style atom dump files +directly. WIth version 3.8 and above, OVITO can also read and +visualize *grid* style dump files with grid cell data, including +isosurface images of the grid cell values. Note that settings made via the :doc:`dump_modify ` command can also alter the format of individual values and content of From 90cf1d6fca53cf9c52ce4cc1d2a163195fae9281 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 22 Dec 2022 12:25:49 -0500 Subject: [PATCH 4/5] update VMD compatibility info, too. --- doc/src/dump.rst | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/doc/src/dump.rst b/doc/src/dump.rst index 7242b3d855..4b0f47ec58 100644 --- a/doc/src/dump.rst +++ b/doc/src/dump.rst @@ -250,16 +250,20 @@ the :doc:`dump_modify ` page for details. The *style* keyword determines what kind of data is written to the dump file(s) and in what format. -Note that *atom*, *custom*, *dcd*, *xtc*, and *xyz* style dump files -can be read directly by `VMD `_, -a popular tool for viewing molecular system. +Note that *atom*, *custom*, *dcd*, *xtc*, *xyz*, and *yaml* style dump +files can be read directly by `VMD `_, +a popular tool for visualizing and analyzing trajectories from atomic +and molecular systems. For reading *netcdf* style dump files, the +netcdf plugin needs to be recompiled from source using a NetCDF version +compatible with the one used by LAMMPS. The bundled plugin binary +uses are very old version that is not compatible. Likewise the `OVITO visualization package `_, popular for materials modeling, can read the *atom*, *custom*, *local*, *xtc*, *cfg*, *netcdf*, and *xyz* style atom dump files -directly. WIth version 3.8 and above, OVITO can also read and +directly. With version 3.8 and above, OVITO can also read and visualize *grid* style dump files with grid cell data, including -isosurface images of the grid cell values. +iso-surface images of the grid cell values. Note that settings made via the :doc:`dump_modify ` command can also alter the format of individual values and content of From d4af1834ec0ef3c55e7dcefa0eb476c0dd9de473 Mon Sep 17 00:00:00 2001 From: Aidan Thompson Date: Thu, 22 Dec 2022 10:44:03 -0700 Subject: [PATCH 5/5] Update dump.rst --- doc/src/dump.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/src/dump.rst b/doc/src/dump.rst index 4b0f47ec58..800542475d 100644 --- a/doc/src/dump.rst +++ b/doc/src/dump.rst @@ -256,7 +256,7 @@ a popular tool for visualizing and analyzing trajectories from atomic and molecular systems. For reading *netcdf* style dump files, the netcdf plugin needs to be recompiled from source using a NetCDF version compatible with the one used by LAMMPS. The bundled plugin binary -uses are very old version that is not compatible. +uses a very old version of NetCDF that is not compatible with LAMMPS. Likewise the `OVITO visualization package `_, popular for materials modeling, can read the *atom*, *custom*,