Skip to main content

Computing neighbor lists for atomistic system

Project description

Vesin: fast neighbor lists for atomistic systems

Documentation Tests

English 🇺🇸⁠/⁠🇬🇧 Occitan French 🇫🇷 Arpitan Gallo‑Italic Catalan Spanish 🇪🇸 Italian 🇮🇹
neighbo(u)r vesin voisin vesin 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.3.3.tar.gz (27.8 kB view details)

Uploaded Source

Built Distributions

vesin-0.3.3-py3-none-win_amd64.whl (54.5 kB view details)

Uploaded Python 3 Windows x86-64

vesin-0.3.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (52.2 kB view details)

Uploaded Python 3 manylinux: glibc 2.17+ x86-64

vesin-0.3.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (50.9 kB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARM64

vesin-0.3.3-py3-none-macosx_11_0_arm64.whl (22.3 kB view details)

Uploaded Python 3 macOS 11.0+ ARM64

vesin-0.3.3-py3-none-macosx_10_13_x86_64.whl (22.2 kB view details)

Uploaded Python 3 macOS 10.13+ x86-64

File details

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

File metadata

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

File hashes

Hashes for vesin-0.3.3.tar.gz
Algorithm Hash digest
SHA256 4a3685959e6a7b416f0347afcd99896c299a8a8430f815f91c499b062e135754
MD5 85fe3241dfdf490292653201214ea8c4
BLAKE2b-256 b6c3ad22ce127cfe00d99f8c31161f2a3a5addb4dfba6aebf16a7afe1721dbc7

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for vesin-0.3.3-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 c601179354ea881769671a140f60275956615ce06afcb902f4bd2b97eee5c870
MD5 0a744214312821b9d3b7bcf11f50973b
BLAKE2b-256 c8c4450a8694714af85aa8e86ae9132ec373d728d39fd9ace0a982d9fa9d5800

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for vesin-0.3.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 369d640e763fedddcc24b3a083b106ccd8a62796b4661829ee7f550432e3582c
MD5 2dd2e8c6e7617ae3d44bc2dbf8e61b1b
BLAKE2b-256 215026255be936d584ad491b8434b62315b8d2081375713865782abc2139be6d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for vesin-0.3.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 f3752034f4adf86950186bb1ae5c75d529aeced20abe48a943683d1c34232926
MD5 aa4b5a9b2930f27c2482560954a2319d
BLAKE2b-256 06353ee2e9777f68c8520b9f295a2d67dd9efd7b117821da0424471e40394d87

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for vesin-0.3.3-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 9019c7eed6d480c45322bbb209620b5840b143853d31cadc475d3075e4e5b2c3
MD5 2b89f3e11ad53bbebf1db9aa10263aef
BLAKE2b-256 c2215495effe3bf291fb8509f88c8404c1d06932e8192dbd972e45c1247e5d4b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for vesin-0.3.3-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 e6155d13878f23e5fce48efec0767fab5c2ec3ecfa71a5f195eaf26ad22aa0ca
MD5 5e7420e2359dec1641655a22bc6116c2
BLAKE2b-256 bd34731cd73ffe4c0fdccbd19de77cce918300eef6b3feaf678ed533f31bdc4e

See more details on using hashes here.

Supported by

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