fix bug with the temperature in -s gromacs

main
Aditya Wibawa Sakti 10 months ago
parent b316af7e71
commit 50197aaf02
  1. 4
      bin/cmmde.py
  2. BIN
      lib/__pycache__/cmmde_rdf.cpython-310.pyc
  3. 5
      lib/cmmde_rdf.py

@ -487,14 +487,14 @@ if opt.software == 'gromacs':
#SBATCH --time=168:0:0
export OMP_NUM_THREADS=1
cd $PWD
$GROMACS_COMMAND -mt {} -mp {} -ct {} -pt {} -pp {} -l {} -cat {} -gen {} -Nump {} -prod {} -nprod {} -nequil {} -dt {} -ctype {} -nnpt {} -comp {} -np {}""".format(opt.terlarut,opt.pelarut,opt.c_terlarut,opt.persen_terlarut,opt.persen_pelarut,opt.lapang,opt.cation,opt.generate_dftbinp,opt.NumPelarut,opt.production,opt.nprod,opt.nequil,opt.deltat,opt.charge_type,opt.nnpt,opt.compress,opt.nproc,opt.rcol),file=fout)
$GROMACS_COMMAND -mt {} -mp {} -ct {} -pt {} -pp {} -l {} -cat {} -gen {} -Nump {} -prod {} -nprod {} -nequil {} -dt {} -ctype {} -nnpt {} -comp {} -np {} -rc {} -t {}""".format(opt.terlarut,opt.pelarut,opt.c_terlarut,opt.persen_terlarut,opt.persen_pelarut,opt.lapang,opt.cation,opt.generate_dftbinp,opt.NumPelarut,opt.production,opt.nprod,opt.nequil,opt.deltat,opt.charge_type,opt.nnpt,opt.compress,opt.nproc,opt.rcol,opt.temp),file=fout)
os.system('sbatch run.sh')
else:
with open('run.sh','w') as fout:
print("""#!/bin/bash
export OMP_NUM_THREADS=1
cd $PWD
$GROMACS_COMMAND -mt {} -mp {} -ct {} -pt {} -pp {} -l {} -cat {} -gen {} -Nump {} -prod {} -nprod {} -nequil {} -dt {} -ctype {} -nnpt {} -comp {} -np {}""".format(opt.terlarut,opt.pelarut,opt.c_terlarut,opt.persen_terlarut,opt.persen_pelarut,opt.lapang,opt.cation,opt.generate_dftbinp,opt.NumPelarut,opt.production,opt.nprod,opt.nequil,opt.deltat,opt.charge_type,opt.nnpt,opt.compress,opt.nproc,opt.rcol),file=fout)
$GROMACS_COMMAND -mt {} -mp {} -ct {} -pt {} -pp {} -l {} -cat {} -gen {} -Nump {} -prod {} -nprod {} -nequil {} -dt {} -ctype {} -nnpt {} -comp {} -np {} -rc {} -t {}""".format(opt.terlarut,opt.pelarut,opt.c_terlarut,opt.persen_terlarut,opt.persen_pelarut,opt.lapang,opt.cation,opt.generate_dftbinp,opt.NumPelarut,opt.production,opt.nprod,opt.nequil,opt.deltat,opt.charge_type,opt.nnpt,opt.compress,opt.nproc,opt.rcol,opt.temp),file=fout)
os.system('chmod +x run.sh')
os.system('./run.sh')

@ -15,8 +15,9 @@ def rdf(traject,latt,pair,endrange,resolution):
cell.append(list(map(float, line.split()[1:4])))
box = lattice.Lattice(cell)
(lx, ly, lz), (a, b, c) = box.lengths_and_angles
# (lx, ly, lz), (a, b, c) = box.lengths_and_angles
lx, ly, lz = box.lengths
a, b, c = box.angles
u = MDAnalysis.Universe(traject, format='XYZ')
u.dimensions = np.array([lx, ly, lz, a, b, c], dtype=np.float32)

Loading…
Cancel
Save