Skip to content

Commit

Permalink
Adapt binary header fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ladinesa committed Sep 17, 2024
1 parent 08fd7ed commit 4129622
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 9 deletions.
8 changes: 2 additions & 6 deletions atomisticparsers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,7 @@ class EntryPoint(ParserEntryPoint):
def load(self):
from nomad.parsing import MatchingParserInterface

return MatchingParserInterface(
**self.dict(),
mainfile_binary_header=self.mainfile_binary_header,
mainfile_binary_header_re=self.mainfile_binary_header_re,
)
return MatchingParserInterface(**self.dict())


amber_parser_entry_point = EntryPoint(
Expand Down Expand Up @@ -78,7 +74,7 @@ def load(self):
python_package='atomisticparsers.asap',
mainfile_binary_header_re=b'AFFormatASE\\-Trajectory',
mainfile_mime_re='application/octet-stream',
mainfile_name_re=r'.*.traj$', # can this be specified here? to directly check for the emt calculator maybe? somehow we need to seperate the general ase/traj parser from the asap parser
mainfile_name_re=r'.*.traj$', # can this be specified here? to directly check for the emt calculator maybe? somehow we need to seperate the general ase/traj parser from the asap parser
parser_class_name='atomisticparsers.asap.AsapParser',
code_name='ASAP',
code_homepage='https://wiki.fysik.dtu.dk/asap',
Expand Down
4 changes: 3 additions & 1 deletion atomisticparsers/gromacs/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@
x_gromacs_section_input_output_files,
)
from atomisticparsers.utils import MDAnalysisParser, MDParser
from simulationworkflowschema.molecular_dynamics import get_bond_list_from_model_contributions
from simulationworkflowschema.molecular_dynamics import (
get_bond_list_from_model_contributions,
)

re_float = r'[-+]?\d+\.*\d*(?:[Ee][-+]\d+)?'
re_n = r'[\n\r]'
Expand Down
4 changes: 3 additions & 1 deletion atomisticparsers/lammps/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@
x_lammps_section_control_parameters,
)
from atomisticparsers.utils import MDAnalysisParser, MDParser
from simulationworkflowschema.molecular_dynamics import get_bond_list_from_model_contributions
from simulationworkflowschema.molecular_dynamics import (
get_bond_list_from_model_contributions,
)


re_float = r'[-+]?\d+\.*\d*(?:[Ee][-+]\d+)?'
Expand Down
5 changes: 4 additions & 1 deletion atomisticparsers/utils/mdanalysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,10 @@

from nomad.units import ureg
from nomad.parsing.file_parser import FileParser
from simulationworkflowschema.molecular_dynamics import BeadGroup, shifted_correlation_average
from simulationworkflowschema.molecular_dynamics import (
BeadGroup,
shifted_correlation_average,
)


MOL = 6.022140857e23
Expand Down

0 comments on commit 4129622

Please sign in to comment.