Skip to content

Low dimensional benchmark#355

Open
JonathanSchmidt1 wants to merge 25 commits intoddmms:mainfrom
JonathanSchmidt1:low_dimensional_benchmark
Open

Low dimensional benchmark#355
JonathanSchmidt1 wants to merge 25 commits intoddmms:mainfrom
JonathanSchmidt1:low_dimensional_benchmark

Conversation

@JonathanSchmidt1
Copy link

Pre-review checklist for PR author

PR author must check the checkboxes below when creating the PR.

Summary

Adds relaxation of two-dimensional and one-dimensional crystal structures benchmarking energies and areas/lengths.

Linked issue

Resolves #354

Progress

  • Calculations
  • Analysis
  • Application
  • Documentation

Testing

mace-mpa-0

New decorators/callbacks

No

JonathanSchmidt1 and others added 25 commits February 2, 2026 22:25
Initial implementation of benchmark for 2D crystal structures from
Alexandria database. Uses cell mask to constrain relaxation to in-plane
directions only.

Metrics:
- Area MAE (Ų/atom): In-plane area per atom vs PBE reference
- Energy MAE (eV/atom): Energy per atom vs PBE reference
- Convergence (%): Percentage of structures that converged

Data source: alexandria_2d_001.json.bz2 from Alexandria database

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add generic download_data() and load_structures() functions for both 2D/1D
- Add get_length_per_atom() for 1D chain length calculation
- Add relax_low_dimensional() with dimensionality parameter for cell masks
- Add 1D metrics: Length MAE, Energy MAE, Convergence
- Add 1D parity plots for length and energy
- Parametrize test function for both 2D and 1D dimensionalities
- Update app with 1D plot configurations

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Document the new low-dimensional relaxation benchmark including:
- Summary of 2D and 1D structure relaxation
- Metrics: Area/Length MAE, Energy MAE, and Convergence for both 2D and 1D
- Description of cell masks for constrained relaxation
- Data availability from Alexandria database

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add set_vacuum_padding() function that sets lattice constants to 100 Å
in non-periodic directions while preserving vector directions:
- 2D: sets c vector to 100 Å
- 1D: sets b and c vectors to 100 Å

Apply vacuum padding before relaxation in test function.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add symmetrize_structure() using spglib.standardize_cell()
- Remove FixSymmetry constraint (doesn't work for low-d relaxations)
- Apply symmetrization before vacuum padding and relaxation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Update DEFAULT_DATA_FILES to use lists (2 files for 2D, 1 for 1D)
- Add download_all_data() to download multiple files
- Update load_structures() to pool entries from all files before sampling

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Replace 10 near-identical per-dimensionality fixtures with:
- DIM_CONFIGS dict mapping dimensionality to column/label/unit
- _compute_mae() and _compute_convergence() helpers
- _generate_all_plots() looping over DIM_CONFIGS
- Single parity_plots fixture and loop-based metrics fixture

Reduces 465 lines to 353 lines with no duplication.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace custom symmetrize_structure implementation with
ase.spacegroup.symmetrize.refine_symmetry. Drop spglib import.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove symmetrize_structure(), call refine_symmetry() directly
- Add test_get_area_per_atom and test_get_length_per_atom unit tests

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@ElliottKasoar ElliottKasoar added the new benchmark Proposals and suggestions for new benchmarks label Feb 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new benchmark Proposals and suggestions for new benchmarks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2D/1D Crystal Structure Relaxations

2 participants