← Back to all sparks
P

pymatgen

DEVOPS
Velocity0.0

Python materials genomics analysis library

pymatgen split its core into a separate package without breaking a single import.

materials sciencepackage splitvasp parsingphase diagramsdeprecations
Current state
pymatgen releases on a calendar version whenever enough pull requests accumulate, typically every one to three months, with a wide contributor base and a changelog that is a plain list of merged PRs. The structural event in this window is the March 2026 reorganization that moved core functionality into a separate pymatgen-core repository and PyPI package while keeping pip install pymatgen fully backwards compatible. Around it, the recurring themes are parser correctness for VASP, LOBSTER and JDFTX outputs, phase diagram fixes, and steady deprecation of older API spellings.
Where it's heading
Two things are happening at once: the package is being decomposed so the core materials-science objects can be depended on without the full toolchain, and the I/O layer is being hardened for output files that are partial, malformed, or larger than the parsers assumed. Performance work is opportunistic rather than systematic — a symmetry algorithm here, lazy CLI imports there — driven by contributors hitting bottlenecks in their own workflows. The deprecation cadence is steady enough that downstream code should expect one or two renames per release.
Prediction
Expect pymatgen-core to start versioning independently of the main package, and the LOBSTER and JDFTX parsers to keep receiving the memory and durability work they have drawn in each recent release.

Recent moves

  1. 3mo ago

    2026.5.4: phase diagram hull fixes and a faster pmg CLI

    Two phase-diagram correctness fixes — same-composition entries reappearing in inner hull reduction, and energy_adjustments not clearing properly in clean mode — plus a partial update method for projected phase diagrams. Lazy imports speed up pmg CLI startup, and the LobsterEnv constructors that mixed file paths and objects are deprecated in favor of object-only initialization.

    View source ↗
  2. 4mo ago

    2026.3.23: core functionality moves to a separate pymatgen-core package

    ⚡ SPARK

    The repository is reorganized so core functionality lives in its own repo and ships as a separate PyPI package, with the notes stressing that pip install pymatgen still provides everything it did before. The same release rewrites the LOBSTER parsers with a memory-efficient streaming architecture, which is the largest single I/O change in this window.

    View source ↗
  3. 10mo ago

    2025.10.7: PROCAR k-point indexing bug attributed data to the wrong points

    The headline fix matters more than its one-line entry suggests: when repeated k-points were skipped while reading PROCAR, projections, eigenvalues, occupations and weights were attributed to the wrong k-points, and the following point came back with NaN projections. Anyone plotting band structures along a k-path was affected. The rest is hygiene — print replaced with logging, a missing sdist on PyPI restored, and two deprecations.

    View source ↗
  4. 1y ago

    2025.6.14: single source of truth for POTCAR directories, faster symmetry analysis

    The CLI is made to use the same POTCAR directory structure as pymatgen.io.vasp.inputs, which the author flags as possibly breaking for CLI users — a small change with real migration cost. A faster is_periodic_image implementation cuts a documented bottleneck in get_primitive_standard_structure, and JDFTXOutfileSlice.trajectory gains frame properties.

    View source ↗
  5. 1y ago

    2025.5.28: orjson becomes the default JSON handler

    orjson becomes a required dependency and the default JSON handler where no custom encoder is needed — a serialization speedup that every caller gets without changing code. The JDFTX parser also gets a durability pass so that partially dumped output files no longer abort parsing.

    View source ↗
  6. 1y ago

    2025.5.2: lxml removed from Vasprun parsing

    A single-line release removing lxml on the grounds that it is slower for many Vasprun parsing situations. One dependency fewer, no API change.

    View source ↗