Crates.io | fastatomstruct |
lib.rs | fastatomstruct |
version | |
source | src |
created_at | 2025-01-30 20:33:15.929539 |
updated_at | 2025-02-14 21:10:39.850442 |
description | A Python package for the analysis of atomic structures and dynamics |
homepage | |
repository | |
max_upload_size | |
id | 1536834 |
Cargo.toml error: | TOML parse error at line 22, column 1 | 22 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include` |
size | 0 |
fastatomstruct
is a Python package (mostly written in Rust) that includes functions to calculate atomic structural quantities.
If possible, thread-based parallelization (using rayon
) is employed to speed up calculations and take advantage of multicore processors.
The documentation can be found here.
The package can currently calculate the following quantities:
This example uses the Atomistic Simulation Environment, which can also be installed using pip (pip install ase
) and is a dependency of fastatomstruct
.
from ase.build import bulk
from fastatomstruct import all_distances, coordination_numbers
# Lithium in the BCC phase with the unit cell repeated
# 10x10x10 times
atoms = bulk("Li", "bcc", 3.45).repeat((10, 10, 10))
# Atomic distances
dists = all_distances(atoms)
# Coordination numbers with a cutoff of 3 A
coordination = coordination_numbers(atoms, 3)
fastatomstruct
can be installed from the Python Package Index. Currently, Windows (x86_64), Linux (x86_64, aarch64), and Mac OS X (x86_64, aarch64) with a Python version >= 3.8 are supported. In addition, your x86_64 processor has to support AVX2 instructions. Most processors since 2015 should meet those criteria. If your system doesn't, you can still install fastatomstruct
from source (see next subsection).
To run the installation, use
pip install fastatomstruct
If you want to use image parallelization with fastatomstruct.ipar
(see documentation), you should also install mpi4py
. Please consult the corresponding documentation for installation instructions and prerequisites.
Installing fastatomstruct
from source requires
maturin
, a Python package that can e.g. be installed using pip3 install --upgrade maturin
To build the Python wheel, run
maturin build --release
The resulting wheel will be located in target/wheels/
. You can install it using
python3 -m pip install target/wheels/fastatomstruct-version.whl
Replace "version" with your actual Python version.
The package can then be used in Python using e.g. from fastatomstruct import coordination_numbers
.
We welcome contributions to fastatomstruct
. To contribute, please follow these steps:
If you encounter any issues or bugs while using fastatomstruct
, please report them on our [https://zivgitlab.uni-muenster.de/ag-salinga/fastatomstruct/-/issues). Provide as much detail as possible, including steps to reproduce the issue and any relevant error messages.
For support and questions, you can also use the GitLab issues page. We will do our best to assist you in a timely manner.