Skip to main content

Python Materials Genomics is a robust materials analysis code that defines core object representations for structures and molecules with support for many electronic structure codes. It is currently the core analysis code powering the Materials Project (https://materialsproject.org).

Project description

Logo

CI Status codecov PyPI Downloads Conda Downloads Requires Python 3.9+ arXiv

Pymatgen (Python Materials Genomics) is a robust, open-source Python library for materials analysis. These are some of the main features:

  1. Highly flexible classes for the representation of Element, Site, Molecule and Structure objects.
  2. Extensive input/output support, including support for VASP, ABINIT, CIF, Gaussian, XYZ, and many other file formats.
  3. Powerful analysis tools, including generation of phase diagrams, Pourbaix diagrams, diffusion analyses, reactions, etc.
  4. Electronic structure analyses, such as density of states and band structure.
  5. Integration with the Materials Project REST API.

Pymatgen is free to use. However, we also welcome your help to improve this library by making your contributions. These contributions can be in the form of additional tools or modules you develop, or feature requests and bug reports. The following are resources for pymatgen:

Why use pymatgen?

  1. It is (fairly) robust. Pymatgen is used by thousands of researchers and is the analysis code powering the Materials Project. The analysis it produces survives rigorous scrutiny every single day. Bugs tend to be found and corrected quickly. Pymatgen also uses Github Actions for continuous integration, which ensures that every new code passes a comprehensive suite of unit tests.
  2. It is well documented. A fairly comprehensive documentation has been written to help you get to grips with it quickly.
  3. It is open. You are free to use and contribute to pymatgen. It also means that pymatgen is continuously being improved. We will attribute any code you contribute to any publication you specify. Contributing to pymatgen means your research becomes more visible, which translates to greater impact.
  4. It is fast. Many of the core numerical methods in pymatgen have been optimized by vectorizing in numpy/scipy. This means that coordinate manipulations are fast. Pymatgen also comes with a complete system for handling periodic boundary conditions.
  5. It will be around. Pymatgen is not a pet research project. It is used in the well-established Materials Project. It is also actively being developed and maintained by the Materials Virtual Lab, the ABINIT group and many other research groups.
  6. A growing ecosystem of developers and add-ons. Pymatgen has contributions from materials scientists all over the world. We also now have an architecture to support add-ons that expand pymatgen's functionality even further. Check out the contributing page and add-ons page for details and examples.

Installation

The version at the Python Package Index PyPI is always the latest stable release that is relatively bug-free and can be installed via pip:

pip install pymatgen

If you'd like to use the latest unreleased changes on the main branch, you can install directly from GitHub:

pip install -U git+https://github.com/materialsproject/pymatgen

The minimum Python version is 3.9. Some extra functionality (e.g., generation of POTCARs) does require additional setup (see the pymatgen docs).

Change Log

See GitHub releases, docs/CHANGES.md or commit history in increasing order of details.

Using pymatgen

Please refer to the official pymatgen docs for tutorials and examples.

How to cite pymatgen

If you use pymatgen in your research, please consider citing the following work:

Shyue Ping Ong, William Davidson Richards, Anubhav Jain, Geoffroy Hautier, Michael Kocher, Shreyas Cholia, Dan Gunter, Vincent Chevrier, Kristin A. Persson, Gerbrand Ceder. Python Materials Genomics (pymatgen): A Robust, Open-Source Python Library for Materials Analysis. Computational Materials Science, 2013, 68, 314-319. doi:10.1016/j.commatsci.2012.10.028

In addition, some of pymatgen's functionality is based on scientific advances/principles developed by the computational materials scientists in our team. Please refer to the pymatgen docs on how to cite them.

Soliciting contributions to 2nd pymatgen paper

If you are a long-standing pymatgen contributor and would like to be involved in working on an updated pymatgen publication, please fill out this co-author registration form or contact @shyuep, @mkhorton and @janosh with questions.

License

Pymatgen is released under the MIT License. The terms of the license are as follows:

The MIT License (MIT) Copyright (c) 2011-2012 MIT & LBNL

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About the Pymatgen Development Team

Shyue Ping Ong (@shyuep) of the Materials Virtual Lab started Pymatgen in 2011 and is still the project lead. Janosh Riebesell (@janosh) and Matthew Horton (@mkhorton) are co-maintainers.

The pymatgen development team is the set of all contributors to the pymatgen project, including all subprojects.

Our Copyright Policy

Pymatgen uses a shared copyright model. Each contributor maintains copyright over their contributions to pymatgen. But, it is important to note that these contributions are typically only changes to the repositories. Thus, the pymatgen source code, in its entirety is not the copyright of any single person or institution. Instead, it is the collective copyright of the entire pymatgen Development Team. If individual contributors want to maintain a record of what changes/contributions they have specific copyright on, they should indicate their copyright in the commit message of the change, when they commit the change to one of the pymatgen repositories.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

pymatgen-2023.12.18.tar.gz (7.2 MB view details)

Uploaded Source

Built Distributions

pymatgen-2023.12.18-cp311-cp311-win_amd64.whl (7.7 MB view details)

Uploaded CPython 3.11 Windows x86-64

pymatgen-2023.12.18-cp311-cp311-win32.whl (7.7 MB view details)

Uploaded CPython 3.11 Windows x86

pymatgen-2023.12.18-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.1 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

pymatgen-2023.12.18-cp311-cp311-macosx_10_9_x86_64.whl (7.7 MB view details)

Uploaded CPython 3.11 macOS 10.9+ x86-64

pymatgen-2023.12.18-cp310-cp310-win_amd64.whl (7.7 MB view details)

Uploaded CPython 3.10 Windows x86-64

pymatgen-2023.12.18-cp310-cp310-win32.whl (7.7 MB view details)

Uploaded CPython 3.10 Windows x86

pymatgen-2023.12.18-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.0 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

pymatgen-2023.12.18-cp310-cp310-macosx_10_9_x86_64.whl (7.7 MB view details)

Uploaded CPython 3.10 macOS 10.9+ x86-64

pymatgen-2023.12.18-cp39-cp39-win_amd64.whl (7.7 MB view details)

Uploaded CPython 3.9 Windows x86-64

pymatgen-2023.12.18-cp39-cp39-win32.whl (7.7 MB view details)

Uploaded CPython 3.9 Windows x86

pymatgen-2023.12.18-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.0 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

pymatgen-2023.12.18-cp39-cp39-macosx_10_9_x86_64.whl (7.7 MB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

File details

Details for the file pymatgen-2023.12.18.tar.gz.

File metadata

  • Download URL: pymatgen-2023.12.18.tar.gz
  • Upload date:
  • Size: 7.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.7

File hashes

Hashes for pymatgen-2023.12.18.tar.gz
Algorithm Hash digest
SHA256 56c0041fe5431ac1b8f8c0c17d06091c4d61082c3a99924f3940d73ebb6656eb
MD5 4d16b4d47198b714aaca5837269c7675
BLAKE2b-256 67f631cfbcf941391f5165085643e134d2bb3b8a61967035a2abd522ef0f4fe7

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 c5321838f4f5164f86756e136061d3080a10dafe9434b2a16207bb2b03b931fb
MD5 f930fe8550eddc6bd74ef0617c485fe3
BLAKE2b-256 f9492b6fe7d4c02c11f2c7d955d64f70bb8d6701d0c21e081d103c7cd83cfdb0

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp311-cp311-win32.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 d01c60c7b39d734d416091e6b698b45348b7dea103143ed2db588c5dbe126d52
MD5 fa253a8eda93bfb1a04c61c743e33627
BLAKE2b-256 4cdc3667d9fcff0e9ddf64ef5465172c8db14a4f400aad2252bebd2e3ae4d683

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 87eadd6a1dfbe9315c5af78b4126fe4dfb9ae7823f5b2631946813ddef03bf0f
MD5 579dbc496beabe450491a7622abd9e3e
BLAKE2b-256 0b0bdbd249ef03e640289d9b4d7266db43b07274d38b01a29583acc0044a4280

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp311-cp311-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 205f75daf789c6d50d0daec66b061b413a09e97e9157d8b0e0f94ccf347d1e6e
MD5 05fae95567ef2c0e24d172dd0b9b52b0
BLAKE2b-256 c7fcf4af119c3011a75c5b351a9558753784a97f8d172fce07d462a9d7a61e50

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 1bc7b39ed27a28c4feafa973f8fd46ec7bdf572494ac4783724e046f24e942e9
MD5 45ec908b8761fa158fbdc57d81d9e61d
BLAKE2b-256 36c0724625e1d5f3bdee7464c32c1b2f7e474a341a3d938144da6bb8f515d4e9

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp310-cp310-win32.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 af4e19b37c7b0318e4b82299eca46e16dc4894a233c07b11be35d2ca22873c41
MD5 9245d460218269319f3bfd6454acf81e
BLAKE2b-256 5095bff2d812876b364aba16f7a9afb72b8b51d81536ca3b9aeb646250f501c2

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c0f8a65c0337bdd7a284694151a6afa26b2dd23edd3c18a36e8285c2d2911cbd
MD5 b63eb58c7291f2f9f3a66c548e311b17
BLAKE2b-256 1bd8922cfb21d953c5447c36faad7b157c9b76bf0f95267f598d430bd3ded16f

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 139202bb110354e4ad9a924962f819d55e61fb6505e71cf1a76ff8399c433df8
MD5 262fa7ca96f63e7d8345cb68d9f9e1d1
BLAKE2b-256 6d1200bad81732996bc12845d8ecc2a872c36970cf2e0c85b449c7f70179c12f

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 1aca935f04b1d452fea3367cbf955bc950fa81f5c9386d242300f97335b952de
MD5 5ab7865f6ab335cffc95d84c9bd3ce48
BLAKE2b-256 3efa71dd4b0b1ea45d4f9e59ab5974cf00ff45ec8ea510c51a9936552284fe76

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp39-cp39-win32.whl.

File metadata

  • Download URL: pymatgen-2023.12.18-cp39-cp39-win32.whl
  • Upload date:
  • Size: 7.7 MB
  • Tags: CPython 3.9, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.7

File hashes

Hashes for pymatgen-2023.12.18-cp39-cp39-win32.whl
Algorithm Hash digest
SHA256 fa8686ad00ed0b6771463c39ce7cf02a9bd4900eb2614516fd864cff975de3f9
MD5 aed832ac4a31c8c43f81612882296c65
BLAKE2b-256 617723ff649069476f25e8f48869e04710de92cb715659267dac7d5ee73ab52a

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 725d7325c28ce944649bdae88a2d3eb5e0b523593e1b2ac33996929421d7d11f
MD5 792e8c2212e2e846af14a041423f5565
BLAKE2b-256 81038898e122df6249cef60fcb91b6519d6a665f9c0b82ba9d59c399658220ef

See more details on using hashes here.

File details

Details for the file pymatgen-2023.12.18-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for pymatgen-2023.12.18-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 b61999fc42a5320f43c430daab21a646e90f455615f6e450b365be444c9bbe41
MD5 6c0c2cb31459370ce938f0927b80e1f9
BLAKE2b-256 70163a67a35fe0c66b35cc382517774dad5cc068f311838187e712fe954423d9

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 Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page