Repository navigation
Conversation
spkdeploy compiles a potential with the make_fx tracer of CompiledPotential, torch.export and AOTInductor into a package for the LAMMPS pair style, which is rewritten next to load it. - model.compile: trace(), the make_fx core of CompiledPotential, shared by CompiledPotential and deploy - interfaces.lammps_interface: LammpsPotential (flat tensors with a local mask for ghost atoms; energy, per-atom energies, forces and edge virial) and deploy_lammps (trace, export, AOTI package with metadata, checked against eager before it is written) - spkdeploy moved into schnetpack.cli; cli_scripts removed - SO3net and PaiNN created tensors in float32 in float64 models; SO3net's float32 sqrt(0.5) caused the ~2e-8 deviation of its float64 package - tests: parity with the model, domains with ghost atoms adding up to the periodic system, rejected models, packages and spkdeploy (slow) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pair_style schnetpack loads the packages spkdeploy writes with
AOTIModelPackageLoader instead of TorchScript, and runs on any number of
MPI ranks.
- schnetpack_model.{h,cpp}: loads and runs a package, independent of
LAMMPS; checks its metadata and torch version, picks the GPU per rank on
a node; keeps torch headers out of style_pair.h
- pair_schnetpack: ghost atoms as graph nodes with a local mask (newton pair
on, ghost cutoff raised to the receptive field plus skin), or
no_domain_decomposition on one rank with periodic shifts; per-atom
energies and the virial from the model
- built as a LAMMPS plugin (CMakeLists.txt, C++20 for torch >= 2.14), or
into LAMMPS with patch_lammps.sh
- tests/model_check.cpp, run by a slow test against Python; deploy_lammps
compiles into a temporary directory next to the package
- how-to and aspirin example updated; not yet run in LAMMPS
- schnetpack[compile] extra for torch >= 2.14
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
lammps_check.py deploys a random PaiNN potential and compares LAMMPS to Python: energy, per-atom energies, forces and virial with domain decomposition on 1, 2 and 4 ranks and with no_domain_decomposition, NVE trajectories across these setups, and an NPT run. Runs that hang are killed after --timeout. The LAMMPS workflow builds LAMMPS with the pair style as a plugin and patched in, and runs the check on CPU. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
No description provided.