Skip to main content

Computing neighbor lists for atomistic system

Project description

Vesin: fast neighbor lists for atomistic systems

Documentation Tests

English 🇺🇸⁠/⁠🇬🇧 Occitan Arpitan French 🇫🇷 Gallo‑Italic Catalan Spanish 🇪🇸 Italian 🇮🇹
neighbo(u)r vesin vesin voisin visin veí vecino vicino

Vesin is a fast and easy to use library computing neighbor lists for atomistic system. We provide an interface for the following programing languages:

  • C (also compatible with C++). The project can be installed and used as a library with your own build system, or included as a single file and built directly by your own build system;
  • Python;
  • TorchScript, with both a C++ and Python interface;

Installation

To use the code from Python, you can install it with pip:

pip install vesin

See the documentation for more information on how to install the code to use it from C or C++.

Usage instruction

You can either use the NeighborList calculator class:

import numpy as np
from vesin import NeighborList

# positions can be anything compatible with numpy's ndarray
positions = [
    (0, 0, 0),
    (0, 1.3, 1.3),
]
box = 3.2 * np.eye(3)

calculator = NeighborList(cutoff=4.2, full_list=True)
i, j, S, d = calculator.compute(
    points=positions,
    box=box,
    periodic=True,
    quantities="ijSd"
)

We also provide a function with drop-in compatibility to ASE's neighbor list:

import ase
from vesin import ase_neighbor_list

atoms = ase.Atoms(...)

i, j, S, d = ase_neighbor_list("ijSd", atoms, cutoff=4.2)

See the documentation for more information on how to use the code from C or C++.

Benchmarks

You can find below benchmark result computing neighbor lists for increasingly large diamond supercells, using an AMD 3955WX CPU and an NVIDIA 4070 Ti SUPER GPU. You can run this benchmark on your system with the script at benchmarks/benchmark.py. Missing points indicate that a specific code could not run the calculation (for example, NNPOps requires the cell to be twice the cutoff in size, and can't run with large cutoffs and small cells).

Benchmarks

License

Vesin is is distributed under the 3 clauses BSD license. By contributing to this code, you agree to distribute your contributions under the same license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vesin-0.4.2.tar.gz (38.2 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

vesin-0.4.2-py3-none-win_amd64.whl (35.6 kB view details)

Uploaded Python 3Windows x86-64

vesin-0.4.2-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (59.7 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

vesin-0.4.2-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl (58.3 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

vesin-0.4.2-py3-none-macosx_11_0_arm64.whl (29.9 kB view details)

Uploaded Python 3macOS 11.0+ ARM64

vesin-0.4.2-py3-none-macosx_10_13_x86_64.whl (29.8 kB view details)

Uploaded Python 3macOS 10.13+ x86-64

File details

Details for the file vesin-0.4.2.tar.gz.

File metadata

  • Download URL: vesin-0.4.2.tar.gz
  • Upload date:
  • Size: 38.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for vesin-0.4.2.tar.gz
Algorithm Hash digest
SHA256 46bcfdc4d56490d43a6d8c5882b900b5cf49cff68b6ffb78d442ff85d0104d4f
MD5 8ff109eb7359596243ca182236c9825c
BLAKE2b-256 1befcb19340bb52bdf3ae7dfac7eb7e44b6ef9174b331403c2c0130a28e1a34c

See more details on using hashes here.

File details

Details for the file vesin-0.4.2-py3-none-win_amd64.whl.

File metadata

  • Download URL: vesin-0.4.2-py3-none-win_amd64.whl
  • Upload date:
  • Size: 35.6 kB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for vesin-0.4.2-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 70f57f618c3426c1376fbf7b79e06166e5e530e57cf787e974160a1a53a49d95
MD5 0720feb2c5fb7929561b3edfab679baa
BLAKE2b-256 cae3556a107f6496b3f7f99c60eadf037cde6b37cf6b033f643c38617e95b8df

See more details on using hashes here.

File details

Details for the file vesin-0.4.2-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for vesin-0.4.2-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 72b7c3e26860c5a751fa18676f9487057a1a1f0c50993fedfe1909e33ba608f2
MD5 4ff40a651772b4d432030d73a8025014
BLAKE2b-256 f666fe9c41fcf5fe73637997e632a488637d8283fe7bed327b147d26e4964a20

See more details on using hashes here.

File details

Details for the file vesin-0.4.2-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.

File metadata

File hashes

Hashes for vesin-0.4.2-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
Algorithm Hash digest
SHA256 16fb90d0f37ff52d35de339be0722165500f7913e216ac98f70303f160417c86
MD5 ae852f283bfe6111003821b3f76ad131
BLAKE2b-256 af6e36b718e21a3f274117bd4a40f6d45c5a8d5a59c575b97d286858929080fc

See more details on using hashes here.

File details

Details for the file vesin-0.4.2-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: vesin-0.4.2-py3-none-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 29.9 kB
  • Tags: Python 3, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for vesin-0.4.2-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 22cd5adcedccc766f98f6185bc737e3f43fc21e6aee54b8803ced17b8e7460fb
MD5 c9fb78800dcb67e731d2c1af4a4963f9
BLAKE2b-256 6a1d8a061603f318e965f50c39e46a56ed372a987b48c40011709f2a9219add0

See more details on using hashes here.

File details

Details for the file vesin-0.4.2-py3-none-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for vesin-0.4.2-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 0c04157b86ebd2aba4a2e254fc2bba47cf4a7069884b81c45e2fd802e3dd906e
MD5 6c977d15fbf3984cb38c2de610ec1dc9
BLAKE2b-256 609ca6d1640e69f72b22a6c6023fe5d623a739688083bf95b62ddf4e06d53596

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page