torch_sim.neighborsΒΆ

Neighbor list implementations for torch-sim.

This module provides multiple neighbor list implementations with automatic fallback based on available dependencies. The API supports both single-system and batched (multi-system) calculations.

Available Implementations:
  • Primitive: Pure PyTorch implementation (always available)

  • Vesin: High-performance neighbor lists (optional, requires vesin package)

  • Batched: Optimized for multiple systems (torch_nl_n2, torch_nl_linked_cell)

Default Neighbor Lists:

The module automatically selects the best available implementation: - Priority: alchemiops_nl_n2 > vesin_nl_ts > torch_nl_linked_cell

Functions

torchsim_nl

Compute neighbor lists with automatic selection of best available implementation.

Classes

ALCHEMIOPS_AVAILABLE

bool(x) -> bool

VESIN_AVAILABLE

bool(x) -> bool

Modules

alchemiops

Alchemiops-based neighbor list implementations.

nbody

Pure-PyTorch triplet and quadruplet interaction index builders.

torch_nl

Batched neighbor list implementations for multiple systems.

vesin

Vesin-based neighbor list implementations.