Lammps parser model method#147
Draft
Bernadette-Mohr wants to merge 36 commits into
Draft
Conversation
Pull Request Test Coverage Report for Build 21947708520Details
💛 - Coveralls |
* docs: Add parser testing strategy discussion paper * fixed code highlighting syntax * Added method/force field parameter parsing * removed unneccessary docs page * ForceField.contributions not added to archive * Updated test-data to work with current MDAnalysis (2.10.0). Replaced hardcoded exlusion of GMX2024 with dynamic support check, to reflect major changes in MDAnalysis * Added timestep, thermostat and parostat parameter parsing * Linting fix (#145) * Fixed Linting error * bond_list parsing and test * Added angle and dihedral parsing * patches for processing (#152) * Update src/nomad_simulation_parsers/parsers/lammps/file_parsers.py Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: ladinesa <67910858+ladinesa@users.noreply.github.com> Co-authored-by: Joseph Rudzinski <JFRudzinski@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* resolve ruff PLC0207 by limiting split operations to one split each * tighten behavior
* Fixed Ruff complaint * Fixed failing test/skipping tests until update of test data * Added creation and parsing of system hierarchy * Fixed system hierarchy not being fully parsed, added tests/data/protein_small, updated tests * Resolved Copilot review comments. * Optimized the system hierarchy parsing, minimizing number of trajectory searches. * Added negation exeption for test data log files to gitignore * Pruned water trajectories to reduce test time
* Temporarily disable mappings to `convergence_tolerance_energy_difference` and `convergence_tolerance_force_maximum` in abinit and gromacs schema packages. This commit restores functionality. Follow-up commit will migrate to the new `WorkflowConvergenceTarget` API.
* Workaround for recursive workflow tasks * Update src/nomad_simulation_parsers/schema_packages/h5md.py Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Updated test_h5md_parser to accomodate workaround * Added TODO marker to test_h5md_parser for workflow regression workaround --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Add convergence target and SCF steps parsing to 8 parsers Adds support for parsing workflow convergence criteria (`EnergyConvergenceTarget`, `ForceConvergenceTarget`) and SCF iteration data (`SCFSteps`) following schema updates in nomad-simulations#260. **Parsers updated:** abinit, ams, crystal, exciting, fhiaims, gpaw, quantumespresso, vasp **Implementation:** Uses direct class instantiation approach. Future migration to dict-based `m_def` mapping annotations should be tracked separately (see PR #162 for reference). **Testing:** 39 unit tests added, all passing. Validated with production samples in `.tests/pr-150-convergence/`. Depends on nomad-simulations#260 Co-authored-by: Joseph Rudzinski <joseph.rudzinski@physik.hu-berlin.de> Co-authored-by: Nathan Daelman <nathan.daelman@physik.hu-berlin.de>
* implement particle state reassignment fix * revert pyproject.toml changes * add more tests
* Resolved field naming conflict (values -> coupling_parameters) * Renamed coupling_parameters to lambda_values to improve clarity
Add support for capturing k-point mesh configuration from FHI-aims output and control.in files. This is the first step toward full KMesh schema population. Additions: - Add `k_offset` regex capture to out_parser.py for output file - Add `k_grid` and `k_offset` regex captures to ControlParser in common.py - Parse k-grid as integer array and k-offset as float array
Wire up KMesh support through schema annotations to map k-grid and k-offset data to the NOMAD schema. Changes: - Import `numerical_settings` module in fhiaims.py - Add DFT class with numerical_settings mapping annotation - Add NumericalSettings class with KMesh subsection mapping - Add KMesh class with direct field mappings for `grid` and `offset` - Add test for k_mesh (currently shows model_method is empty, needs investigation) Note: model_method population appears to happen during normalization, not during parsing. Further investigation needed to verify k_mesh data flow through the full parsing+normalization pipeline.
Directly populate DFT and KMesh sections after parsing as temporary workaround while investigating why mapping annotations don't trigger section creation. Issue: DFT.m_def annotation with '.@' path does not create DFT section despite being identical to working patterns in VASP, GPAW, etc. Temporary solution: - Create DFT section programmatically after convert() - Extract k_grid/k_offset from parsed data - Instantiate KMesh and add to DFT.numerical_settings This approach works but bypasses the annotation system. Need to find root cause of annotation failure and implement proper fix.
Add k-point mesh (k_grid and k_offset) parsing and mapping to NOMAD schema for FHI-aims. The implementation uses the KSpace → k_mesh → KMesh hierarchy as defined in the NOMAD schema. Changes: - Parse k_grid and k_offset from FHI-aims output using regex quantities - Add KSpace and KMesh schema classes with mapping annotations - Map parsed k-point data to DFT → KSpace → KMesh structure - Add comprehensive test coverage for k-mesh functionality The key insight was that KMesh is not a direct subclass of NumericalSettings - it must be wrapped in KSpace (which is a NumericalSettings) to be added to `DFT.numerical_settings`. This follows the same pattern used by VASP parser.
This reverts commit 28ac2c2.
…ion" This reverts commit 01662ab.
This reverts commit 85778bc.
This reverts commit f860134.
Add `KMesh` support for FHI-aims parser Parse k_grid and k_offset from FHI-aims output and map to `DFT.numerical_settings.KSpace.k_mesh`. Set FHI-aims default offset=[0,0,0] (Gamma-centered) when not present.
* Added parsing of masses and (partial) charges * Rebasing onto current develop * Extended atom parameter parsing to include chemical_symbol and atomic_number, if available * WIP * Adapted schema to archive derived properties from MolecularDynamicsResults * Implemented explicitly archiving ParticleParameters, generalized all references to atom to particle * Fixed Ruff complaint * Added temporary check for availability of new feature in nomad_simulations * More guards * Adjusted parser and schema to changes in nomad-simulations.force_field, updated program.version regex * Recovered some missing quantities * Added some more missing Quantities * fix: block MappingParser Level 3 task recursion for GROMACS workflows * Extended parser to handle CG systems, started adding free energy parameter parsing * corrected model_method structure, added workarounds for nested subsection issues * Added free energy parameter parsing * fix: clean up unused imports, remove magic numbers * implemented atom/particle classification * fix: organize inputs * added parsing of free energy parameters * fix: rename lambdas valuse -> coupling_parameters to resolve naming conflict with MappingParser * Adapted parser to reflect resolved field naming conflict * Resolved field naming conflict (values -> lambda_values) (#169) * Resolved field naming conflict (values -> coupling_parameters) * Renamed coupling_parameters to lambda_values to improve clarity * renamed coupling_parameters to lambda_values * closed implementation gap to add free-energy inputs via XVG parser. * linting stuff * Conditionally skip test until related PR is merged * optimized tests, adressed Copilot comments * fix: rename Outpus -> Outputs in gromacs schema, update TODO PR ref to #375 * Update src/nomad_simulation_parsers/parsers/gromacs/parser.py Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * reabsing * adressed review comments, reduced code redundancy in the parser * removed stale dependency --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Corrected annotation for ForceField, ForceCalculation, ParticleParametersContainer * Fixed comments * explicit type annotations for pylance compliance
* Pin nmr schema version * Update nmr version
* Add SCF convergence criteria mapping for FHI-aims Add SelfConsistency annotation using multi-mapper pattern to extract convergence criteria (energy, density, eigenvalues) as separate instances alongside KSpace in DFT.numerical_settings. --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Haoyu Yang <yang@Haoyus-Air.localdomain>
* Add tests * Use utc reference for datetime
* Implement parsing of vasp charge density * Update pyproject.toml * Try using nomad-lab develop * Remove index-url * Revert and exclude vasp entry point * Add charge density annotation to vasp schema
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Extends the LAMMPS parser to populate the MolecularDynamicsMethod schema from nomad-simulations, enabling standardized extraction of MD simulation metadata (thermostat/barostat settings, integrator parameters, ensemble type) from LAMMPS log and data files.
Scope
Out of scope (What is explicitly not included (to avoid scope creep)?)
Status
Dependencies / Blockers
Testing / Validation
Linked Issues / Context
Use GitHub keywords where applicable.
Reviewer Notes
Anything reviewers should pay special attention to? Trade-offs, known limitations, or areas of uncertainty.