Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion cclib/parser/serenityparser.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ def extract(self, inputfile, line):
diis = float(line.split()[2])
scftargets.append(numpy.array([ethresh, rmsd, diis]))
self.set_attribute("scftargets", scftargets)
if "Total Energy" in line:

if line.startswith("Total Energy ("):
self.append_attribute("scfenergies", float(line.split()[3]))

if line.strip().startswith("Origin chosen as:"):
Expand Down Expand Up @@ -177,3 +178,19 @@ def extract(self, inputfile, line):
homos = int(line.split()[0])
line = next(inputfile)
self.set_attribute("homos", [homos - 1]) # Serenity starts at 1, python at 0

if line.split()[1:3] == ["MP2", "Results"] or line.split()[1:3] == [
"(Local-)MP2",
"Results",
]:
# Serenity has no higher order than MP2 and cannot do geometry optimization with it,
# but still may contain several MP2 energies in one file.
if hasattr(self, "mpenergies"):
self.logger.warning("Warning: Multiple MP2 energies in Serenity!")
line = next(inputfile)
# skip forward to string "Total Energy", but only for max 20 lines
i = 0
while not line.strip().startswith("Total Energy") and i < 20:
line = next(inputfile)
i += 1
self.append_attribute("mpenergies", [line.split()[2]])
5 changes: 5 additions & 0 deletions data/Serenity/serenity1.6.1/water_mp2/h2o.xyz
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
3

O 1.784914 1.262422 0.511985
H 2.648237 1.072929 0.131631
H 1.183168 1.256816 -0.238835
Binary file not shown.
Binary file not shown.
6 changes: 6 additions & 0 deletions data/Serenity/serenity1.6.1/water_mp2/h2o/h2o.energies.res
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
System_ID 1761076383904056638
ENUM_INDEX ENERGY
5 9.1468130260
6 -122.5542759448
102 37.8218786769
601 0.0000000000
Binary file not shown.
123 changes: 123 additions & 0 deletions data/Serenity/serenity1.6.1/water_mp2/h2o/h2o.settings
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
#=======================================================
# NOTE:
# This file contains the entire list of settings
# that were stored in one instance of the Settings
# class.
# The settings given here have not necessarily been
# used, e.g. a functional might not have been needed.
# in a HF calculations.
#=======================================================
+system
NAME h2o
IDENTIFIER 1761076383904056638
PATH ./h2o/
CHARGE 0
IGNORECHARGE false
SPIN 0
GEOMETRY h2o.xyz
SCFMODE RESTRICTED
METHOD HF
+dft
FUNCTIONAL BP86
DISPERSION NONE
-dft
+scf
INITIALGUESS ATOMSCF
MAXCYCLES 100
WRITERESTART 5
ENERGYTHRESHOLD 5e-08
RMSDTHRESHOLD 1e-08
DAMPING SERIES
SERIESDAMPINGSTART 0.7
SERIESDAMPINGEND 0.2
SERIESDAMPINGSTEP 0.05
SERIESDAMPINGINITIALSTEPS 2
STATICDAMPINGFACTOR 0.7
ENDDAMPERR 0.05
USELEVELSHIFT true
USEOFFDIAGLEVELSHIFT false
MINIMUMLEVELSHIFT 0
DIISFLUSH 1000
DIISSTARTERROR 0.05
DIISMAXSTORE 10
DIISTHRESHOLD 5e-07
CANORTHTHRESHOLD 1e-07
USEADIIS false
ALLOWNOTCONVERGED false
ROHF NONE
SUHFLAMBDA 0.01
DEGENERACYTHRESHOLD 0
-scf
+basis
LABEL 3-21G
AUXJLABEL RI_J_WEIGEND
MAKESPHERICALBASIS true
INTEGRALTHRESHOLD 0
INTEGRALINCREMENTTHRESHOLDSTART 1e-08
INTEGRALINCREMENTTHRESHOLDEND 0
INCREMENTALSTEPS 5
BASISLIBPATH /home/lukas/serenity/data/basis/
FIRSTECP 37
DENSFITJ RI
DENSFITK NONE
DENSFITLRK NONE
DENSFITCORR RI
CDTHRESHOLD 1e-06
EXTENDSPHERICALACDSHELLS SIMPLE
INTCONDITION -1
SECONDCD 1e-08
CDOFFSET 0.01
-basis
+grid
GRIDTYPE SSF
RADIALGRIDTYPE AHLRICHS
SPHERICALGRIDTYPE LEBEDEV
BLOCKSIZE 128
ACCURACY 4
SMALLGRIDACCURACY 2
BLOCKAVETHRESHOLD 1e-11
BASFUNCRADIALTHRESHOLD 1e-09
WEIGHTTHRESHOLD 1e-14
SMOOTHING 3
GRIDPOINTSORTING true
IMPORTGRID none
-grid
+efield
USE false
ANALYTICAL false
POS1 { 0 0 0 }
POS2 { 0 0 1 }
DISTANCE 50
NRINGS 50
RADIUS 1
FIELDSTRENGTH 0.001
-efield
+pcm
USE false
CAVITY DELLEY
SCALING true
RADIITYPE BONDI
MINRADIUS 0.377
SOLVERTYPE CPCM
SOLVENT H2O
CORRECTION 0
PROBERADIUS 1
EPS 1
PATCHLEVEL 0
MINDISTANCE 0.2
OVERLAPFACTOR 0.7
CACHESIZE 128
LLARGE 7
LSMALL 4
ALPHA 50
PROJECTIONCUTOFF 5
ONECAVITY false
CONNECTIVITYFACTOR 2
NUMBERDENSITY 1
TEMPERATURE 298.15
CAVITYFORMATION false
CAVITYPROBERADIUS 5
-pcm
+extcharges
-extcharges
-system
5 changes: 5 additions & 0 deletions data/Serenity/serenity1.6.1/water_mp2/h2o/h2o.xyz
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
3
ID: 1761076383904056638
O 1.784914000000 1.262422000000 0.511985000000
H 2.648237000000 1.072929000000 0.131631000000
H 1.183168000000 1.256816000000 -0.238835000000
18 changes: 18 additions & 0 deletions data/Serenity/serenity1.6.1/water_mp2/water_mp2.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
+system
name h2o
geometry h2o.xyz
scfmode restricted
method hf
+basis
label 3-21g
-basis
-system

+task scf
act h2o
-task

+task mp2
act h2o
mp2type ao
-task
Loading
Loading