Skip to main content

Data structures for crystallography

Project description

crystals

Documentation Status PyPI Package latest release Conda-forge Version DOI badge

crystals is a library of data structure and algorithms to manipulate abstract crystals in a Pythonic way. crystals helps with reading crystallographic files (like .cif and .pdb), provides access to atomic positions, scattering utilities, allows for symmetry determination, and indexing of diffraction peaks. Although crystals can be used on its own, it was made to be integrated into larger projects (like scikit-ued).

Take a look at the documentation for more information and examples.

Installation

crystals is available on the Python Package Index:

pip install crystals

For users of the conda package manager, crystals is also available from the conda-forge channel:

conda install -c conda-forge crystals

From source

crystals can also be installed from source:

git clone https://github.com/LaurentRDC/crystals.git
cd crystals
python setup.py install

You can install the latest development version using pip as well:

python -m pip install git+git://github.com/LaurentRDC/crystals.git

To build documentation, you will need a few more packages, listed in dev-requirements.txt. For example, to build documentation from source:

git clone https://github.com/LaurentRDC/crystals.git
cd crystals
pip install -r dev-requirements.txt
python setup.py build_sphinx

Documentation

The documentation, including user guides as well as detailed reference, is available here: https://crystals.readthedocs.io/

Development

Tests can be run with the pytest package:

python -m pytest --pyargs crystals

Some optional tests might be skipped if dependencies are not installed, e.g. ASE.

Citations

As this package is a spinoff from scikit-ued, please consider citing the following publication if you find crystals useful:

L. P. René de Cotret, M. R. Otto, M. J. Stern. and B. J. Siwick, An open-source software ecosystem for the interactive exploration of ultrafast electron scattering data, Advanced Structural and Chemical Imaging 4:11 (2018) DOI: 10.1186/s40679-018-0060-y.

Underlying algorithms provided by spglib are described in the following publication:

A. Togo and I. Tanaka, spglib: a software library for crystal symmetry search. https://arxiv.org/abs/1808.01590 (written at version 1.10.4).

Structure parsing from CIF files has been tested for correctness against CIF2CELL, detailed here:

Torbjorn Bjorkman, CIF2Cell: Generating geometries for electronic structure programs, Computer Physics Communications 182, 1183-1186 (2011) DOI: 10.1016/j.cpc.2011.01.013

Structure parsing from PDB files has been tested for correctness against Bio.PDB, detailed here:

Hamelryck, T., Manderick, B. PDB parser and structure class implemented in Python. Bioinformatics 19: 2308–2310 (2003)

Atomic weights are reported in the following publication:

Meija, J., Coplen, T., Berglund, M., et al. (2016). Atomic weights of the elements 2013 (IUPAC Technical Report). Pure and Applied Chemistry, 88(3), pp. 265-291. Retrieved 30 Nov. 2016, DOI:10.1515/pac-2015-0305

Covalent radii are reported in the following article:

Cordero, B. et al. (2008). Covalent radii revisited. Dalton Transactions, issue 21, pp. 2832-2838. The Royal Society of Chemistry. DOI: 10.1039/B801115j

Support / Report Issues

All support requests and issue reports should be filed on Github as an issue.

License

crystals is made available under the GPLv3 license. For more details, see LICENSE.

Related projects

  • Streaming operations on NumPy arrays are available in the npstreams package.
  • Interactive exploration of ultrafast electron diffraction data with the iris-ued package.
  • Data structures and algorithms to handle ultrafast electron scattering data in the scikit-ued package.

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

crystals-1.6.1.tar.gz (159.0 kB view details)

Uploaded Source

Built Distributions

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

crystals-1.6.1-py3.9.egg (363.1 kB view details)

Uploaded Egg

crystals-1.6.1-py3.8.egg (362.6 kB view details)

Uploaded Egg

crystals-1.6.1-py3.7.egg (360.5 kB view details)

Uploaded Egg

crystals-1.6.1-py3-none-any.whl (257.8 kB view details)

Uploaded Python 3

File details

Details for the file crystals-1.6.1.tar.gz.

File metadata

  • Download URL: crystals-1.6.1.tar.gz
  • Upload date:
  • Size: 159.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for crystals-1.6.1.tar.gz
Algorithm Hash digest
SHA256 6f22d3b5a46b987c79ea16664ab6f722325f3d9ebc3fc24a089e7c09e086ee9e
MD5 e9fbe05597f5620a386445e9112e78aa
BLAKE2b-256 c79d3393930ea5f772665d7db2eecfd6d2e3dd0a17be937743d4eec0bd501eb0

See more details on using hashes here.

File details

Details for the file crystals-1.6.1-py3.9.egg.

File metadata

  • Download URL: crystals-1.6.1-py3.9.egg
  • Upload date:
  • Size: 363.1 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for crystals-1.6.1-py3.9.egg
Algorithm Hash digest
SHA256 47849882f0eb8f2972868ed29dc0c98a42b3905fb02e90c40a8e27e3f96f28a0
MD5 9913a19b7e055b946dcb2b7820dedddf
BLAKE2b-256 be5108e6df47ddfb9d3fde7d7f57471ce78c247c810a9a4c8ab59dbea76ac7d9

See more details on using hashes here.

File details

Details for the file crystals-1.6.1-py3.8.egg.

File metadata

  • Download URL: crystals-1.6.1-py3.8.egg
  • Upload date:
  • Size: 362.6 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for crystals-1.6.1-py3.8.egg
Algorithm Hash digest
SHA256 3afb8c6ccfa3cdccfcd91083430f887336f27214fc4b59b72792ff19643856c4
MD5 6c8d16087e396838e8203136d264cec6
BLAKE2b-256 208a205abd2b408d6982e2b8db4bfa5f3930e9c680093b622e8e3ef2dfa0aaae

See more details on using hashes here.

File details

Details for the file crystals-1.6.1-py3.7.egg.

File metadata

  • Download URL: crystals-1.6.1-py3.7.egg
  • Upload date:
  • Size: 360.5 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for crystals-1.6.1-py3.7.egg
Algorithm Hash digest
SHA256 d5554c56f62358b16b23d5460f50e0a58c9e2ca3f8e1e64fa8c650221491dae0
MD5 022b4367dda120ea3c973257c3d79eab
BLAKE2b-256 f3bd4bd8472116fb76306be7f816477535bafc8db8881df3abe939051ad66c64

See more details on using hashes here.

File details

Details for the file crystals-1.6.1-py3-none-any.whl.

File metadata

  • Download URL: crystals-1.6.1-py3-none-any.whl
  • Upload date:
  • Size: 257.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for crystals-1.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f26f7511d95deb2439bf66821495bef4925d025b3fe249331b9b1330014c52f9
MD5 fcba3df5db31ebdfa78f7c2020d6a2f8
BLAKE2b-256 1bf98def4d5a50fc5549202f232b77b7a9c23d4888213703bd0075f041b8a102

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