venuspython 1.0.5__tar.gz → 1.0.7__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. {venuspython-1.0.5 → venuspython-1.0.7}/PKG-INFO +1 -1
  2. venuspython-1.0.7/venuspy/__init__.py +1 -0
  3. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/cli.py +115 -80
  4. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/initialSampling.py +413 -113
  5. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/md.py +2 -2
  6. {venuspython-1.0.5 → venuspython-1.0.7}/venuspython.egg-info/PKG-INFO +1 -1
  7. venuspython-1.0.5/venuspy/__init__.py +0 -1
  8. {venuspython-1.0.5 → venuspython-1.0.7}/README.md +0 -0
  9. {venuspython-1.0.5 → venuspython-1.0.7}/pyproject.toml +0 -0
  10. {venuspython-1.0.5 → venuspython-1.0.7}/setup.cfg +0 -0
  11. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/bagelcalc.py +0 -0
  12. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/chempotpycalc.py +0 -0
  13. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/minisgdmlcalc.py +0 -0
  14. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/mopaccalc.py +0 -0
  15. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/nwchemcalc.py +0 -0
  16. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/nwchemexcalc.py +0 -0
  17. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/original_nwchemexcalc.py +0 -0
  18. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/physnetcalc.py +0 -0
  19. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/psi4calc.py +0 -0
  20. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/qcengineGAMESScalc.py +0 -0
  21. {venuspython-1.0.5 → venuspython-1.0.7}/venuspy/calc/xtbcalc.py +0 -0
  22. {venuspython-1.0.5 → venuspython-1.0.7}/venuspython.egg-info/SOURCES.txt +0 -0
  23. {venuspython-1.0.5 → venuspython-1.0.7}/venuspython.egg-info/dependency_links.txt +0 -0
  24. {venuspython-1.0.5 → venuspython-1.0.7}/venuspython.egg-info/entry_points.txt +0 -0
  25. {venuspython-1.0.5 → venuspython-1.0.7}/venuspython.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: venuspython
3
- Version: 1.0.5
3
+ Version: 1.0.7
4
4
  Summary: VENUSpy Initial Sampling and Molecular Dynamics
5
5
  Keywords: moleculardynamics,initialsampling
6
6
  Classifier: Development Status :: 5 - Production/Stable
@@ -0,0 +1 @@
1
+ __version__ = "1.0.7"
@@ -24,38 +24,38 @@ from .md import regularMD, pingpongMD, smoothedMD, r2threshold
24
24
  try:
25
25
  from .calc.bagelcalc import bagelcalculator
26
26
  except ImportError:
27
- print("WARNING: BAGEL has not been loaded ... it will not be available for initial sampling")
27
+ print("#VENUS WARNING: BAGEL HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
28
28
 
29
29
  # Try importing psi4
30
30
  try:
31
31
  from .calc.psi4calc import psi4calculator
32
32
  except ImportError:
33
- print("WARNING: psi4 has not been loaded ... it will not be available for initial sampling")
33
+ print("#VENUS WARNING: PSI4 HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
34
34
 
35
35
  # Try importing xtb (fast, semi-empirical DFT):
36
36
  try:
37
37
  # from tblite.ase import TBLite
38
38
  from .calc.xtbcalc import TBLite
39
39
  except ImportError:
40
- print("WARNING: xtb has not been loaded ... it will not be available for initial sampling")
40
+ print("#VENUS WARNING: XTB HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
41
41
 
42
42
  # Try import NWChem (not NWChemEx)
43
43
  try:
44
44
  from .calc.nwchemcalc import nwchemcalculator
45
45
  except ImportError:
46
- print("WARNING: NWChem has not been loaded ... it will not be available for initial sampling")
46
+ print("#VENUS WARNING: NWCHEM HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
47
47
 
48
48
  # Try importing NWChemEx
49
49
  try:
50
50
  from .calc.nwchemexcalc import nwchemexcalculator
51
51
  except ImportError:
52
- print("WARNING: NWChemEx has not been loaded ... it will not be available for initial sampling")
52
+ print("#VENUS WARNING: NWCHEMEX HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
53
53
 
54
54
  # Try importing QCEngine/GAMESS
55
55
  try:
56
56
  from .calc.qcengineGAMESScalc import qcengineGAMESScalculator
57
57
  except ImportError:
58
- print("WARNING: QCEngine/GAMESS has not been loaded ... it will not be available for initial sampling")
58
+ print("#VENUS WARNING: QCENGINE/GAMESS HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
59
59
 
60
60
  # Try importing sGDML
61
61
  try:
@@ -67,26 +67,26 @@ try:
67
67
  from .calc.minisgdmlcalc import miniSGDMLCalculator
68
68
 
69
69
  except ImportError:
70
- print("WARNING: sGDML has not been loaded ... it will not be available for initial sampling")
70
+ print("#VENUS WARNING: SGDML HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
71
71
 
72
72
  # Try importing chempotpy
73
73
  try:
74
74
  from .calc.chempotpycalc import chempotpyCalculator
75
75
  except ImportError:
76
- print("WARNING: chempotpy has not been loaded ... it will not be available for initial sampling")
76
+ print("#VENUS WARNING: CHEMPOTPY HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
77
77
 
78
78
  # Try importing Schnet
79
79
  try:
80
80
  import schnetpack as spk
81
81
  import torch
82
82
  except ImportError:
83
- print("WARNING: Schnet has not been loaded ... it will not be available for initial sampling")
83
+ print("#VENUS WARNING: SCHNET HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
84
84
 
85
85
  # Try importing Physnet
86
86
  try:
87
87
  from .calc.physnetcalc import PNCalculator
88
88
  except ImportError:
89
- print("WARNING: Physnet has not been loaded ... it will not be available for initial sampling")
89
+ print("#VENUS WARNING: PHYSNET HAS NOT BEEN LOADED ... IT WILL NOT BE AVAILABLE FOR INITIAL SAMPLING")
90
90
 
91
91
 
92
92
 
@@ -104,6 +104,8 @@ except ImportError:
104
104
 
105
105
  def main():
106
106
 
107
+ global r2threshold
108
+
107
109
  parser = argparse.ArgumentParser(description="Do a single MD trajectory using a initial geometry (and momenta) and a sGDML model",formatter_class=argparse.ArgumentDefaultsHelpFormatter)
108
110
  parser.add_argument("initialGeometryFile", type=str, help="XYZ file with initial geometry; if initial conditions are sampled in the script, then this argument is required but is just an example XYZ")
109
111
  parser.add_argument("PESinputFile", type=str, help="PES input file (may be a psi4 input file or a sGDML .npz model)")
@@ -128,17 +130,19 @@ def main():
128
130
  parser.add_argument("--E0", type=float, help="The initial total energy to track the drift in total energy (e.g. if the trajectory is being restarted)",default=None)
129
131
  parser.add_argument("--n_threads", type=int, help="The number of threads to ask psi4 to use")
130
132
 
131
- parser.add_argument("--INITQPa", type=str, help="Initial sampling method for atoms in first group ('semiclassical', 'microcanonical', 'thermal', or None)", default="")
133
+ parser.add_argument("--INITQPa", type=str, help="Initial sampling method for atoms in first group ('semiclassical', 'microcanonical', 'thermal', 'microcanonicalnormalmode', or None)", default="")
132
134
  parser.add_argument("--NVIBa", type=int, help="Vibrational quantum number of atoms in first group (supply if using the 'semiclassical' initial sampling)")
133
135
  parser.add_argument("--NROTa", type=int, help="Rotational quantum number of atoms in first group (supply if using the 'semiclassical' initial sampling)")
136
+ parser.add_argument("--EVIBNMODESa", type=str, help="List of normal mode vibrational energies of atoms in first group (supply if using the 'microcanonicalnormalmode' initial sampling)")
134
137
  parser.add_argument("--EVIBa", type=float, help="Vibrational energy of atoms in first group (supply if using the 'microcanonical' initial sampling)")
135
138
  parser.add_argument("--EROTa", type=float, help="Rotational energy of atoms in first group (supply if using the 'microcanonical' initial sampling)")
136
139
  parser.add_argument("--TVIBa", type=float, help="Vibrational temperature of atoms in first group (supply if using the 'thermal' initial sampling)")
137
140
  parser.add_argument("--TROTa", type=float, help="Rotational temperature of atoms in first group (supply if using the 'thermal' initial sampling)")
138
141
 
139
- parser.add_argument("--INITQPb", type=str, help="Initial sampling method for atoms in second group ('semiclassical', 'microcanonical', 'thermal', or None)", default="")
142
+ parser.add_argument("--INITQPb", type=str, help="Initial sampling method for atoms in second group ('semiclassical', 'microcanonical', 'thermal', 'microcanonicalnormalmode', or None)", default="")
140
143
  parser.add_argument("--NVIBb", type=int, help="Vibrational quantum number of atoms in second group (supply if using the 'semiclassical' initial sampling)")
141
144
  parser.add_argument("--NROTb", type=int, help="Rotational quantum number of atoms in second group (supply if using the 'semiclassical' initial sampling)")
145
+ parser.add_argument("--EVIBNMODESb", type=str, help="List of normal mode vibrational energies of atoms in second group (supply if using the 'microcanonicalnormalmode' initial sampling)")
142
146
  parser.add_argument("--EVIBb", type=float, help="Vibrational energy of atoms in second group (supply if using the 'microcanonical' initial sampling)")
143
147
  parser.add_argument("--EROTb", type=float, help="Rotational energy of atoms in second group (supply if using the 'microcanonical' initial sampling)")
144
148
  parser.add_argument("--TVIBb", type=float, help="Vibrational temperature of atoms in second group (supply if using the 'thermal' initial sampling)")
@@ -147,21 +151,6 @@ def main():
147
151
 
148
152
  ########################################################################################
149
153
 
150
- # A function to print the potential, kinetic and total energy
151
- def printenergy(a,step,energyflag):
152
- if ("ERROR" in energyflag):
153
- epot = 0.0
154
- ekin = a.get_kinetic_energy() / (units.kcal/units.mol)
155
- print('@Epot = %.3f Ekin = %.3f (T=%3.0fK) '
156
- 'Etot = %.3f kcal/mol Step = %8d %s' % (epot, ekin, ekin / (len(a) * 1.5 * 8.617281e-5), epot + ekin, step, energyflag))
157
- else:
158
- epot = a.get_potential_energy() / (units.kcal/units.mol)
159
- ekin = a.get_kinetic_energy() / (units.kcal/units.mol)
160
- print('@Epot = %.3f Ekin = %.3f (T=%3.0fK) '
161
- 'Etot = %.3f kcal/mol Step = %8d %s' % (epot, ekin, ekin / (len(a) * 1.5 * 8.617281e-5), epot + ekin, step, energyflag))
162
-
163
- ########################################################################################
164
-
165
154
  # Get the various arguments
166
155
  Qfile = args["initialGeometryFile"]
167
156
  input_path = args["PESinputFile"]
@@ -191,18 +180,29 @@ def main():
191
180
  optimize_flag = args["optimize"]
192
181
 
193
182
  if ((Nsteps is None) or (Nprint is None) or (dt is None)):
194
- raise ValueError("For MD, need to specify these three: --production --interval --time_step")
183
+ raise ValueError("#VENUS FOR MD, NEED TO SPECIFY THESE THREE ARGUMENTS: --production --interval --time_step")
195
184
 
196
185
  n_threads = args["n_threads"]
197
186
  if (n_threads is None): n_threads = 1
198
187
 
188
+
199
189
  samplingMethod = [ args["INITQPa"], args["INITQPb"] ]
200
190
  vibrationSampling = []
201
191
  rotationSampling = []
202
192
  if (samplingMethod[0] == "semiclassical"):
203
193
  vibrationSampling.append(args["NVIBa"])
204
194
  rotationSampling.append(args["NROTa"])
205
- elif ("microcanonical" in samplingMethod[0]):
195
+ elif (samplingMethod[0] == "microcanonicalnormalmode"):
196
+ normalmodeinput = args["EVIBNMODESa"]
197
+ try:
198
+ vibrationSampling.append([float(x) for x in normalmodeinput.split(",")])
199
+ except:
200
+ raise ValueError("#VENUS ERROR IN READING NORMAL MODE SAMPLING INPUTS (EVIBNMODESA) ... SHOULD BE COMMA-SEPARATED STRING OF VIBRATIONAL ENERGIES FOR EACH MODE")
201
+ rotationSampling.append(args["EROTa"])
202
+ elif (samplingMethod[0] == "microcanonical"):
203
+ vibrationSampling.append(args["EVIBa"])
204
+ rotationSampling.append(args["EROTa"])
205
+ elif (samplingMethod[0] == "microcanonical-quantum"):
206
206
  vibrationSampling.append(args["EVIBa"])
207
207
  rotationSampling.append(args["EROTa"])
208
208
  else:
@@ -211,12 +211,23 @@ def main():
211
211
  if (samplingMethod[1] == "semiclassical"):
212
212
  vibrationSampling.append(args["NVIBb"])
213
213
  rotationSampling.append(args["NROTb"])
214
- elif ("microcanonical" in samplingMethod[1]):
214
+ elif (samplingMethod[1] == "microcanonicalnormalmode"):
215
+ normalmodeinput = args["EVIBNMODESb"]
216
+ try:
217
+ vibrationSampling.append([float(x) for x in normalmodeinput.split(",")])
218
+ except:
219
+ raise ValueError("#VENUS ERROR IN READING NORMAL MODE SAMPLING INPUTS (EVIBNMODESB) ... SHOULD BE COMMA-SEPARATED STRING OF VIBRATIONAL ENERGIES FOR EACH MODE")
220
+ rotationSampling.append(args["EROTb"])
221
+ elif (samplingMethod[1] == "microcanonical"):
222
+ vibrationSampling.append(args["EVIBb"])
223
+ rotationSampling.append(args["EROTb"])
224
+ elif (samplingMethod[1] == "microcanonical-quantum"):
215
225
  vibrationSampling.append(args["EVIBb"])
216
226
  rotationSampling.append(args["EROTb"])
217
227
  else:
218
228
  vibrationSampling.append(args["TVIBb"])
219
229
  rotationSampling.append(args["TROTb"])
230
+
220
231
 
221
232
  # Note:
222
233
  # Right now, all arguments are mandatory (even though this does
@@ -243,16 +254,16 @@ def main():
243
254
  try_qcenginegamess = False
244
255
  if (input_path.endswith(('.npz',))):
245
256
 
246
- print("Input file '"+input_path+"' looks like a sGDML file so will attempt to read it in as such...")
257
+ print("#VENUS INPUT FILE '"+input_path+"' LOOKS LIKE A SGDML FILE SO WILL ATTEMPT TO READ IT IN AS SUCH...")
247
258
  try:
248
259
  calc = SGDMLCalculator(input_path)
249
260
  try_sgdml = True
250
261
  except:
251
- print(" Could not load file '"+input_path+"' as a sGDML model!")
262
+ print("#VENUS COULD NOT LOAD FILE '"+input_path+"' AS A SGDML MODEL!")
252
263
  try_psi4 = True
253
264
 
254
265
  elif (input_path.endswith(('.physnet.config',))):
255
- print("Input file '"+input_path+"' looks like a PhysNet config file so will attempt to read it in as such...")
266
+ print("#VENUS INPUT FILE '"+input_path+"' LOOKS LIKE A PHYSNET CONFIG FILE SO WILL ATTEMPT TO READ IT IN AS SUCH...")
256
267
 
257
268
  if True:
258
269
  tmp_mol = read(Qfile)
@@ -292,25 +303,40 @@ def main():
292
303
  if (try_schnet):
293
304
 
294
305
  # Initialize the ML ase interface
306
+
307
+ spk_rcut = 6.0
295
308
 
296
- # To accomodate for the older versions of numpy used in Schnet==1.0
297
- np.int = np.int32
298
- np.float = np.float64
299
- np.bool = np.bool_
300
-
301
- calc = spk.interfaces.SpkCalculator(
309
+ # To accomodate for the older versions of numpy used in Schnetpack version < 2.0
310
+ if True:
311
+ np.int = np.int32
312
+ np.float = np.float64
313
+ np.bool = np.bool_
314
+
315
+ # The appropriate arguments for the current Schnetpack version >= 2.0
316
+ if True:
317
+ calc = spk.interfaces.SpkCalculator(
318
+ input_path,
319
+ device="cpu",
320
+ energy_unit="eV",
321
+ position_unit="Angstrom",
322
+ neighbor_list=spk.transform.ASENeighborList(spk_rcut),
323
+ )
324
+
325
+ # The appropriate arguments for the original Schnetpack version < 2.0
326
+ else:
327
+ calc = spk.interfaces.SpkCalculator(
302
328
  input_path,
303
329
  device="cpu",
304
330
  energy="energy", # Name of energies
305
331
  forces="forces", # Name of forces
306
332
  energy_units="kcal/mol",
307
333
  forces_units="kcal/mol/A",
308
- neighbor_list=spk.transform.ASENeighborList(5.0),
309
- )
334
+ neighbor_list=spk.transform.ASENeighborList(spk_rcut),
335
+ )
310
336
 
311
337
 
312
338
  if (try_bagel):
313
- print("Reading input file '"+input_path+"' as a BAGEL input file...")
339
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A BAGEL INPUT FILE...")
314
340
  calc = bagelcalculator(custominputfile=input_path,command='mpirun /mnt/lustre/koa/koastore/rsun_group/camels/BAGEL_1_AV/BAGEL/bin/BAGEL bagel0.json > bagel0.out')
315
341
 
316
342
  # calc.restarts_max = 2 # Max number of allowable SCF restarts
@@ -323,7 +349,7 @@ def main():
323
349
  calc.F_to_eV_Ang = (units.Ha / units.Bohr)
324
350
 
325
351
  if (try_psi4):
326
- print("Reading input file '"+input_path+"' as a psi4 input file...")
352
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A PSI4 INPUT FILE...")
327
353
  calc = psi4calculator(input_path,n_threads=n_threads)
328
354
 
329
355
  calc.restarts_max = 2 # Max number of allowable SCF restarts
@@ -336,11 +362,11 @@ def main():
336
362
  calc.F_to_eV_Ang = (units.Ha / units.Bohr)
337
363
 
338
364
  if (try_xtb):
339
- print("Reading input file '"+input_path+"' as a xtb input file...")
365
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A XTB INPUT FILE...")
340
366
  calc = TBLite(input_path)
341
367
 
342
368
  if (try_qcenginegamess):
343
- print("Reading input file '"+input_path+"' as a QCEngine/GAMESS input file...")
369
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A QCENGINE/GAMESS INPUT FILE...")
344
370
  calc = qcengineGAMESScalculator(input_path,n_threads=n_threads)
345
371
 
346
372
  # To conform to VENUS, we are going to keep the units
@@ -351,7 +377,7 @@ def main():
351
377
  calc.F_to_eV_Ang = (units.Ha / units.Bohr)
352
378
 
353
379
  if (try_nwchemex):
354
- print("Reading input file '"+input_path+"' as a NWChemEx input file...")
380
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A NWCHEMEX INPUT FILE...")
355
381
  calc = nwchemexcalculator(input_path,output_path=output_path,n_threads=n_threads)
356
382
 
357
383
  # To conform to VENUS, we are going to keep the units
@@ -362,7 +388,7 @@ def main():
362
388
  calc.F_to_eV_Ang = (units.Ha / units.Bohr)
363
389
 
364
390
  if (try_nwchem):
365
- print("Reading input file '"+input_path+"' as a NWChem (not NWChemEx) input file...")
391
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A NWCHEM (NOT NWCHEMEX) INPUT FILE...")
366
392
  calc = nwchemcalculator(input_path,output_path=output_path,n_threads=n_threads)
367
393
 
368
394
  # To conform to VENUS, we are going to keep the units
@@ -374,7 +400,7 @@ def main():
374
400
 
375
401
  if (try_chempotpy):
376
402
 
377
- print("Reading input file '"+input_path+"' as a chempotpy input file...")
403
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A CHEMPOTPY INPUT FILE...")
378
404
 
379
405
  # Read the input file
380
406
  with open(input_path, 'r') as f:
@@ -389,7 +415,7 @@ def main():
389
415
 
390
416
  calc = chempotpyCalculator(totallines[0])
391
417
  strippedline=" ".join(line.split()[2:])
392
- print("Single state: {:s} - Chempotpy input: {:s}".format(totalentries[0],strippedline))
418
+ print("#VENUS SINGLE STATE: {:s} - CHEMPOTPY INPUT: {:s}".format(totalentries[0],strippedline))
393
419
 
394
420
  # Note, different chempotpy PES have different maximum allowed distances
395
421
  # For O3 surfaces, 100 A is okay (= 2 * 50 A)
@@ -400,7 +426,7 @@ def main():
400
426
 
401
427
 
402
428
  if (try_mopac):
403
- print("Reading input file '"+input_path+"' as a MOPAC input file...")
429
+ print("#VENUS READING INPUT FILE '"+input_path+"' AS A MOPAC INPUT FILE...")
404
430
  calc = mopaccalculator(input_path,output_path=output_path)
405
431
 
406
432
  # To conform to VENUS, we are going to keep the units
@@ -427,14 +453,14 @@ def main():
427
453
  newMasses = massFile.readlines()
428
454
  massFile.close()
429
455
  if (len(newMasses) != len(mol)): #.masses)):
430
- raise ValueError("Number of masses provided in the isotope mass file does not match the input XYZ")
456
+ raise ValueError("#VENUS NUMBER OF MASSES PROVIDED IN THE ISOTOPE MASS FILE DOES NOT MATCH THE INPUT XYZ! EXITING ...")
431
457
  mol.set_masses([float(i) for i in newMasses])
432
458
 
433
459
  # If a rewind-restart file is given, read in the coordinates (Q),
434
460
  # momenta (P), and energies, for a possible restart
435
461
  if not (rrQPfile is None):
436
462
 
437
- print("REWIND-RESTARTING using this file: " + rrQPfile)
463
+ print("#VENUS REWIND-RESTARTING USING THIS FILE: " + rrQPfile)
438
464
 
439
465
  # Look at the last 1500 frames to restart from (but skip the last rrNskip)
440
466
  rrQPfilehandle = open(rrQPfile)
@@ -458,12 +484,12 @@ def main():
458
484
  Nconsecutivegoodframes += 1
459
485
  E_restart = mol.get_potential_energy()
460
486
  dE = abs(E_original - E_restart) / (units.kcal/units.mol)
461
- print("REWIND-RESTARTING sees that the %d-th to last frame (1-th to last = last frame) has original energy %.3f and restart energy %.3f kcal/mol"
487
+ print("#VENUS REWIND-RESTARTING SEES THAT THE %d-TH TO LAST FRAME (1-TH TO LAST = LAST FRAME) HAS ORIGINAL ENERGY %.3f AND RESTART ENERGY %.3f KCAL/MOL"
462
488
  % (rrNskip+i+1, E_original / (units.kcal/units.mol), E_restart / (units.kcal/units.mol)))
463
489
  except:
464
490
  Nconsecutivegoodframes = 0
465
491
  dE = rrQPdEmax * 2
466
- print("REWIND-RESTARTING sees that the %d-th to last frame (1-th to last = last frame) has original energy %.3f and restart energy NaN kcal/mol"
492
+ print("#VENUS REWIND-RESTARTING SEES THAT THE %d-TH TO LAST FRAME (1-TH TO LAST = LAST FRAME) HAS ORIGINAL ENERGY %.3f AND RESTART ENERGY NAN KCAL/MOL"
467
493
  % (rrNskip+i+1, E_original / (units.kcal/units.mol)))
468
494
 
469
495
  # If they agree within the threshold, then go ahead with the restart
@@ -474,11 +500,11 @@ def main():
474
500
  if (MDtype == "smoothed"): continue
475
501
 
476
502
  rrQPflag = False
477
- print("REWIND-RESTARTING accepts using the %d-th to last frame! (1-th to last = last frame)" % (rrNskip+i+1,))
503
+ print("#VENUS REWIND-RESTARTING ACCEPTS USING THE %d-TH TO LAST FRAME! (1-TH TO LAST = LAST FRAME)" % (rrNskip+i+1,))
478
504
  break
479
505
 
480
506
  if (rrQPflag):
481
- raise ValueError("REWIND-RESTARTING failed ... no acceptable frames to restart from")
507
+ raise ValueError("#VENUS REWIND-RESTARTING FAILED ... NO ACCEPTABLE FRAMES TO RESTART FROM")
482
508
 
483
509
  # If a momenta file is given, read in the momenta
484
510
  # Read it in as a geometry, and then set it into the molecule
@@ -510,33 +536,34 @@ def main():
510
536
  if ((len(atomsInFirstGroup) > 0) and (len(atomsInSecondGroup) > 0)):
511
537
  bimolecular_flag = True
512
538
  if ((ce is None) or (b is None) or (dCM is None)):
513
- raise ValueError("Lacking an argument for bimolecular sampling (collision energy, impact parameter, of center of mass distance)")
539
+ raise ValueError("#VENUS LACKING AN ARGUMENT FOR BIMOLECULAR SAMPLING (COLLISION ENERGY, IMPACT PARAMETER, OR CENTER OF MASS DISTANCE)")
514
540
  else:
515
541
  bimolecular_flag = False
516
542
 
517
- print("")
518
- print("GEOMETRY INPUT")
519
- print(" Input geometry file: ", Qfile)
520
- print("Atoms in first group: ", atomsInFirstGroup)
521
- print("Atoms in second group: ", atomsInSecondGroup)
522
- print("SAMPLING INPUT")
523
- print(" Input momenta file: ", Pfile)
543
+ print("#VENUS ")
544
+ print("#VENUS GEOMETRY INPUT")
545
+ print("#VENUS INPUT GEOMETRY FILE: ", Qfile)
546
+ print("#VENUS ATOMS IN FIRST GROUP: ", *atomsInFirstGroup)
547
+ print("#VENUS ATOMS IN SECOND GROUP: ", *atomsInSecondGroup)
548
+ print("#VENUS SAMPLING INPUT")
549
+ print("#VENUS INPUT MOMENTA FILE: ", Pfile)
524
550
  if (Pfile is None):
525
- print(" Optimize molecules? ", optimize_flag)
526
- print(" Group A sampling method: ", samplingMethod[0])
527
- print(" Group A vibration: ", vibrationSampling[0])
528
- print(" Group A rotation: ", rotationSampling[0])
529
- print(" Group B sampling method: ", samplingMethod[1])
530
- print(" Group B vibration: ", vibrationSampling[1])
531
- print(" Group B rotation: ", rotationSampling[1])
532
- print(" Impact parameter (A): ", b)
533
- print(" Initial separation (A): ", dCM)
534
- print(" Collsion energy (kcal/mol): ", ce)
551
+ print("#VENUS OPTIMIZE MOLECULES? ", optimize_flag)
552
+ print("#VENUS GROUP A SAMPLING METHOD: ", samplingMethod[0])
553
+ print("#VENUS GROUP A VIBRATION: ", vibrationSampling[0])
554
+ print("#VENUS GROUP A ROTATION: ", rotationSampling[0])
555
+ print("#VENUS GROUP B SAMPLING METHOD: ", samplingMethod[1])
556
+ print("#VENUS GROUP B VIBRATION: ", vibrationSampling[1])
557
+ print("#VENUS GROUP B ROTATION: ", rotationSampling[1])
558
+ print("#VENUS IMPACT PARAMETER (A): ", b)
559
+ print("#VENUS INITIAL SEPARATION (A): ", dCM)
560
+ print("#VENUS COLLSION ENERGY (KCAL/MOL): ", ce)
535
561
  else:
536
- print(" Input momenta file: ", Pfile)
562
+ print("#VENUS INPUT MOMENTA FILE: ", Pfile)
537
563
 
538
- print("##############################################################")
539
- print("")
564
+ print("#VENUS")
565
+ print("#VENUS ##############################################################")
566
+ print("#VENUS")
540
567
 
541
568
  # Sample the internal positions and momenta of each of
542
569
  # the two molecules
@@ -545,15 +572,23 @@ def main():
545
572
  samplingMethodA=samplingMethod[0],vibrationalSampleA=vibrationSampling[0],rotationalSampleA=rotationSampling[0],
546
573
  samplingMethodB=samplingMethod[1],vibrationalSampleB=vibrationSampling[1],rotationalSampleB=rotationSampling[1])
547
574
 
548
- print("Sampling internal degrees of freedom...")
575
+ print("#VENUS SAMPLING INTERNAL DEGREES OF FREEDOM ...")
549
576
  sampler.sampleRelativeQP()
577
+
578
+ print("#VENUS")
579
+ print("#VENUS ##############################################################")
580
+ print("#VENUS")
550
581
 
551
582
  if (bimolecular_flag):
552
- print("Sampling relative degrees of freedom...")
583
+ print("#VENUS Sampling relative degrees of freedom...")
553
584
  sampler.sampleAbsoluteQP(ce,dCM=dCM,b=b)
554
585
 
555
586
  else:
556
587
  sampler.centerMolecule(range(Natoms))
588
+
589
+ print("#VENUS")
590
+ print("#VENUS DONE!")
591
+ print("#VENUS")
557
592
 
558
593
  ########################################################################################
559
594
 
@@ -571,7 +606,7 @@ def main():
571
606
  MDgen = smoothedMD(mol,trajfile,dt,Nprint=Nprint,Nrewindsteps=Nrewindsteps,dEmax=dEmax,Edriftmax=Edriftmax,E0=E0,n_threads=n_threads)
572
607
 
573
608
  else:
574
- raise ValueError("MD type '"+MDtype+"' is not valid! Exiting...")
609
+ raise ValueError("#VENUS MD TYPE '"+MDtype+"' IS NOT VALID! EXITING ...")
575
610
 
576
611
  MDgen.production(Nsteps)
577
612