meta 2.0 changes, to fix

parent 5d3975fa
Pipeline #42644 failed with stage
in 12 seconds
......@@ -528,7 +528,7 @@ def get_updateDictionary(self, defname):
# 'settings_geometry_optimization' : MetaInfoMap(startpage),
# 'settings_metadynamics' : MetaInfoMap(startpage),
# 'settings_molecular_dynamics' : MetaInfoMap(startpage),
# 'settings_Monte_Carlo' : MetaInfoMap(startpage),
# 'settings_monte_carlo' : MetaInfoMap(startpage),
# 'geometry_optimization_energy_change' : MetaInfoMap(startpage,
# depends={
# '' : {'imin' : '1'},
......@@ -743,9 +743,9 @@ def get_updateDictionary(self, defname):
# depends=[{'assign' : 'Force Field'}],
# lookupdict=self.mddataDict
# ),
'energy_T0_per_atom' : MetaInfoMap(startpage),
'energy_total_T0_per_atom' : MetaInfoMap(startpage),
'energy_total_T0' : MetaInfoMap(startpage,
'energy_t0_per_atom' : MetaInfoMap(startpage),
'energy_total_t0_per_atom' : MetaInfoMap(startpage),
'energy_total_t0' : MetaInfoMap(startpage,
depends=[{'value' : 'ENERGY'}],
valtype='float',
unitdict=self.unitDict,
......@@ -764,7 +764,7 @@ def get_updateDictionary(self, defname):
'hessian_matrix' : MetaInfoMap(startpage),
'single_configuration_calculation_converged' : MetaInfoMap(startpage),
'single_configuration_calculation_to_system_ref' : MetaInfoMap(startpage),
'single_configuration_to_calculation_method_ref' : MetaInfoMap(startpage),
'single_configuration_calculation_to_method_ref' : MetaInfoMap(startpage),
'time_calculation' : MetaInfoMap(startpage),
'time_single_configuration_calculation_cpu1_end' : MetaInfoMap(startpage),
'time_single_configuration_calculation_cpu1_start' : MetaInfoMap(startpage),
......@@ -787,14 +787,14 @@ def get_updateDictionary(self, defname):
# section_single_energy_van_der_Waals of section_single_configuration_calculation
singlevdw = {
'energy_van_der_Waals_value' : MetaInfoMap(startpage,
'energy_van_der_waals_value' : MetaInfoMap(startpage,
depends=[{'value' : 'VDWAALS'}],
lookupdict=self.mddataDict,
valtype='float',
unitdict=self.unitDict,
unit=self.akmaDict['energy'],
#autoSections=True,
activeSections=['section_energy_van_der_Waals']
activeSections=['section_energy_van_der_waals']
),
}
......@@ -845,13 +845,13 @@ def get_updateDictionary(self, defname):
# Definitions for section_frame_sequence
# ------------------------------------------
frameseq = {
#'frame_sequence_conserved_quantity_frames' : MetaInfoMap(startpage,
#'xxx_to_rm_frame_sequence_conserved_quantity_frames' : MetaInfoMap(startpage,
# depends=[{'store' : 'TS'}],
# valtype='int',
# lookupdict=self.mddataDict
# ),
#'frame_sequence_conserved_quantity_stats' : MetaInfoMap(startpage),
#'frame_sequence_conserved_quantity' : MetaInfoMap(startpage,
#'xxx_conserved_quantity' : MetaInfoMap(startpage,
# depends=[{'store' : ''}],
# valtype='float',
# unitdict=self.unitDict,
......@@ -860,27 +860,27 @@ def get_updateDictionary(self, defname):
# ),
'frame_sequence_continuation_kind' : MetaInfoMap(startpage),
'frame_sequence_external_url' : MetaInfoMap(startpage),
'frame_sequence_kinetic_energy_frames' : MetaInfoMap(startpage,
'xxx_to_rm_frame_sequence_kinetic_energy_frames' : MetaInfoMap(startpage,
depends=[{'store' : 'STEP'}],
valtype='int',
lookupdict=self.mddataDict
),
'frame_sequence_kinetic_energy_stats' : MetaInfoMap(startpage),
'frame_sequence_kinetic_energy' : MetaInfoMap(startpage,
'xxx_kinetic_energy' : MetaInfoMap(startpage,
depends=[{'store' : 'TOTKE'}],
valtype='float',
unitdict=self.unitDict,
unit=self.akmaDict['energy'],
lookupdict=self.mddataDict
),
'frame_sequence_local_frames_ref' : MetaInfoMap(startpage),
'frame_sequence_potential_energy_frames' : MetaInfoMap(startpage,
'frame_sequence_to_frames_ref' : MetaInfoMap(startpage),
'xxx_to_rm_frame_sequence_potential_energy_frames' : MetaInfoMap(startpage,
depends=[{'store' : 'STEP'}],
valtype='int',
lookupdict=self.mddataDict
),
'frame_sequence_potential_energy_stats' : MetaInfoMap(startpage),
'frame_sequence_potential_energy' : MetaInfoMap(startpage,
'xxx_potential_energy' : MetaInfoMap(startpage,
depends=[{'store' : 'ENERGY'}],
valtype='float',
unitdict=self.unitDict,
......@@ -899,13 +899,13 @@ def get_updateDictionary(self, defname):
# unit='atmosphere',
# lookupdict=self.mddataDict
# ),
'frame_sequence_pressure_frames' : MetaInfoMap(startpage,
'xxx_to_rm_frame_sequence_pressure_frames' : MetaInfoMap(startpage,
depends=[{'store' : 'STEP'}],
valtype='int',
lookupdict=self.mddataDict
),
'frame_sequence_pressure_stats' : MetaInfoMap(startpage),
'frame_sequence_pressure' : MetaInfoMap(startpage,
'xxx_instant_pressure' : MetaInfoMap(startpage,
depends=[{'store' : 'PRESSI'}],
valtype='float',
unitdict=self.unitDict,
......@@ -950,13 +950,13 @@ def get_updateDictionary(self, defname):
# unit='Kelvin',
# lookupdict=self.mddataDict
# ),
'frame_sequence_temperature_frames' : MetaInfoMap(startpage,
'xxx_to_rm_frame_sequence_temperature_frames' : MetaInfoMap(startpage,
depends=[{'store' : 'STEP'}],
valtype='int',
lookupdict=self.mddataDict
),
'frame_sequence_temperature_stats' : MetaInfoMap(startpage),
'frame_sequence_temperature' : MetaInfoMap(startpage,
'xxx_instant_temperature' : MetaInfoMap(startpage,
depends=[{'store' : 'TEMPERATURE'}],
valtype='float',
unitdict=self.unitDict,
......@@ -1195,7 +1195,7 @@ def get_updateDictionary(self, defname):
unit=self.akmaDict['energy'],
lookupdict=self.mddataDict
),
#'frame_sequence_to_sampling_ref' : MetaInfoMap(startpage),
#'frame_sequence_to_sampling_method_ref' : MetaInfoMap(startpage),
'geometry_optimization_converged' : MetaInfoMap(startpage,
depends=[
{'test' : [["MINI", " is not None"],
......@@ -1214,7 +1214,7 @@ def get_updateDictionary(self, defname):
# value=(lambda x: np.array(x['val']).flatten().shape[0] if(
# x is not None and x['val'] is not None) else None)(
# self.metaStorage.fetchAttrValue(
# 'frame_sequence_conserved_quantity_frames'
# 'xxx_to_rm_frame_sequence_conserved_quantity_frames'
# )
# )
# ),
......@@ -1222,7 +1222,7 @@ def get_updateDictionary(self, defname):
value=(lambda x: np.array(x['val']).flatten().shape[0] if(
x is not None and x['val'] is not None) else None)(
self.metaStorage.fetchAttrValue(
'frame_sequence_potential_energy_frames'
'xxx_to_rm_frame_sequence_potential_energy_frames'
)
)
),
......@@ -1230,7 +1230,7 @@ def get_updateDictionary(self, defname):
value=(lambda x: np.array(x['val']).flatten().shape[0] if(
x is not None and x['val'] is not None) else None)(
self.metaStorage.fetchAttrValue(
'frame_sequence_kinetic_energy_frames'
'xxx_to_rm_frame_sequence_kinetic_energy_frames'
)
)
),
......@@ -1239,7 +1239,7 @@ def get_updateDictionary(self, defname):
value=(lambda x: np.array(x['val']).flatten().shape[0] if(
x is not None and x['val'] is not None) else None)(
self.metaStorage.fetchAttrValue(
'frame_sequence_potential_energy_frames'
'xxx_to_rm_frame_sequence_potential_energy_frames'
)
)
),
......@@ -1248,7 +1248,7 @@ def get_updateDictionary(self, defname):
value=(lambda x: np.array(x['val']).flatten().shape[0] if(
x is not None and x['val'] is not None) else None)(
self.metaStorage.fetchAttrValue(
'frame_sequence_pressure_frames'
'xxx_to_rm_frame_sequence_pressure_frames'
)
)
),
......@@ -1257,7 +1257,7 @@ def get_updateDictionary(self, defname):
value=(lambda x: np.array(x['val']).flatten().shape[0] if(
x is not None and x['val'] is not None) else None)(
self.metaStorage.fetchAttrValue(
'frame_sequence_temperature_frames'
'xxx_to_rm_frame_sequence_temperature_frames'
)
)
),
......@@ -1402,7 +1402,7 @@ def get_updateDictionary(self, defname):
'number_of_symmetry_operations' : MetaInfoMap(startpage),
'reduced_symmetry_matrices' : MetaInfoMap(startpage),
'reduced_symmetry_translations' : MetaInfoMap(startpage),
'SC_matrix' : MetaInfoMap(startpage),
'sc_matrix' : MetaInfoMap(startpage),
'spacegroup_3D_choice' : MetaInfoMap(startpage),
'spacegroup_3D_hall' : MetaInfoMap(startpage),
'spacegroup_3D_international' : MetaInfoMap(startpage),
......
......@@ -55,7 +55,7 @@ class CHARMMParser(SmartParser.ParserBase):
# dictionary of energy values, which are tracked between SCF iterations and written after convergence
self.totalEnergyList = {
'energy_electrostatic': None,
'energy_total_T0_per_atom': None,
'energy_total_t0_per_atom': None,
'energy_free_per_atom': None,
}
SmartParser.ParserBase.__init__(
......@@ -251,8 +251,8 @@ class CHARMMParser(SmartParser.ParserBase):
startsection=['section_frame_sequence'],
autoopenclose=False)
if self.secSamplingGIndex is not None:
backend.addValue("frame_sequence_to_sampling_ref", self.secSamplingGIndex)
backend.addArrayValues("frame_sequence_local_frames_ref", np.asarray(self.singleConfCalcs))
backend.addValue("frame_sequence_to_sampling_method_ref", self.secSamplingGIndex)
backend.addArrayValues("frame_sequence_to_frames_ref", np.asarray(self.singleConfCalcs))
backend.closeSection("section_frame_sequence", frameSequenceGIndex)
# reset all variables
......@@ -1414,16 +1414,16 @@ class CHARMMParser(SmartParser.ParserBase):
section_singlevdw_Dict = get_updateDictionary(self, 'singlevdw')
updateDictVDW = {
'startSection' : [
['section_energy_van_der_Waals']],
['section_energy_van_der_waals']],
#'muteSections' : [['section_sampling_method']],
'dictionary' : section_singlevdw_Dict
}
self.secVDWGIndex = backend.superBackend.openSection("section_energy_van_der_Waals")
self.secVDWGIndex = backend.superBackend.openSection("section_energy_van_der_waals")
self.metaStorage.update(updateDictVDW)
self.metaStorage.updateBackend(backend.superBackend,
startsection=['section_energy_van_der_Waals'],
startsection=['section_energy_van_der_waals'],
autoopenclose=False)
backend.superBackend.closeSection("section_energy_van_der_Waals", self.secVDWGIndex)
backend.superBackend.closeSection("section_energy_van_der_waals", self.secVDWGIndex)
section_singlecalc_Dict = get_updateDictionary(self, 'singleconfcalc')
updateDict = {
'startSection' : [
......@@ -1440,7 +1440,7 @@ class CHARMMParser(SmartParser.ParserBase):
#if callable(pos_obj):
if self.trajectory.forces is not None:
# Forces in PDB/CHARMM binary/DCD files are stored in kcal/mol/A
SloppyBackend.addArrayValues('atom_forces', np.transpose(np.asarray(
SloppyBackend.addArrayValues('atom_forces_xxx', np.transpose(np.asarray(
self.metaStorage.convertUnits(
self.atompositions.velocities, "kcal/(mol*Angstrom)", self.unitDict))))
# need to transpose array since its shape is [number_of_atoms,3] in the metadata
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment