From 8e3a1e84a629e4776683c9acba3500abcdefed42 Mon Sep 17 00:00:00 2001 From: rohskopf Date: Thu, 23 Jun 2022 12:32:40 -0600 Subject: [PATCH] More cleaning up. --- python/examples/simple.py | 20 ++++++++++---------- src/ML-SNAP/compute_snap.h | 1 - 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/python/examples/simple.py b/python/examples/simple.py index 2f9c191165..8925ce48c0 100755 --- a/python/examples/simple.py +++ b/python/examples/simple.py @@ -5,10 +5,10 @@ # Purpose: mimic operation of examples/COUPLE/simple/simple.cpp via Python # Serial syntax: simple.py in.lammps -# in.simple = LAMMPS input script +# in.lammps = LAMMPS input script -# Parallel syntax: mpirun -np 4 python simple.py in.simple -# in.simple = LAMMPS input script +# Parallel syntax: mpirun -np 4 simple.py in.lammps +# in.lammps = LAMMPS input script # also need to uncomment mpi4py sections below from __future__ import print_function @@ -27,9 +27,9 @@ infile = sys.argv[1] me = 0 # uncomment this if running in parallel via mpi4py -from mpi4py import MPI -me = MPI.COMM_WORLD.Get_rank() -nprocs = MPI.COMM_WORLD.Get_size() +#from mpi4py import MPI +#me = MPI.COMM_WORLD.Get_rank() +#nprocs = MPI.COMM_WORLD.Get_size() from lammps import lammps lmp = lammps() @@ -122,10 +122,10 @@ if me == 0: print("Gather post scatter subset:", boxlo,boxhi,xy,yz,xz,periodicity,box_change = lmp.extract_box() if me == 0: print("Box info",boxlo,boxhi,xy,yz,xz,periodicity,box_change) -#lmp.reset_box([0,0,0],[10,10,8],0,0,0) +lmp.reset_box([0,0,0],[10,10,8],0,0,0) -#boxlo,boxhi,xy,yz,xz,periodicity,box_change = lmp.extract_box() -#if me == 0: print("Box info",boxlo,boxhi,xy,yz,xz,periodicity,box_change) +boxlo,boxhi,xy,yz,xz,periodicity,box_change = lmp.extract_box() +if me == 0: print("Box info",boxlo,boxhi,xy,yz,xz,periodicity,box_change) # uncomment if running in parallel via mpi4py -print("Proc %d out of %d procs has" % (me,nprocs), lmp) +#print("Proc %d out of %d procs has" % (me,nprocs), lmp) diff --git a/src/ML-SNAP/compute_snap.h b/src/ML-SNAP/compute_snap.h index 8dc72c3bd5..2a9a94ef80 100644 --- a/src/ML-SNAP/compute_snap.h +++ b/src/ML-SNAP/compute_snap.h @@ -35,7 +35,6 @@ class ComputeSnap : public Compute { double memory_usage() override; private: - FILE * fh_d; int natoms, nmax, size_peratom, lastcol; int ncoeff, nperdim, yoffset, zoffset; int ndims_peratom, ndims_force, ndims_virial;