Skip to content

docs: recommend run_inference/run_simulation in new-benchmark tutorial#137

Open
lwalew wants to merge 1 commit into
mainfrom
docs/benchmark-tutorial-inference-utils
Open

docs: recommend run_inference/run_simulation in new-benchmark tutorial#137
lwalew wants to merge 1 commit into
mainfrom
docs/benchmark-tutorial-inference-utils

Conversation

@lwalew

@lwalew lwalew commented Jun 8, 2026

Copy link
Copy Markdown
Collaborator

Description - ⚠️ WIP

Updates the contribution docs, highlighting that the provided utilities for running inference and simulations should be used.

Verification

  • uv run sphinx-build -b html docs/source docs/build/html succeeds with no cross-reference warnings for the new content.

🤖 Generated with Claude Code

The "Adding a new benchmark" tutorial showed run_model() calling a
placeholder `_compute_energies_blackbox(self.force_field, ...)`, which
implicitly suggests contributors should call the force field directly.
Doing so loses the behavior the library's helpers provide: support for
both native mlip ForceField objects and generic ASE calculators (i.e.
external/PyTorch models), batched inference, and graceful per-structure
failure handling (returning None instead of crashing the run).

Update the minimal example to use `run_inference`, handle None
predictions, and add a dedicated "Running inference and simulations"
section explaining why `run_inference`/`run_simulation` must be used
instead of calling the model directly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant