JARVIS-Tools

raw JSON →
2026.4.2 verified Mon Apr 27 auth: no python

jarvis-tools is an open-source Python package for data-driven atomistic materials design, developed by NIST. It provides modules for crystal structure analysis, high-throughput DFT workflows, machine learning descriptors, and access to the JARVIS-DFT and JARVIS-FF databases. Current version is 2026.4.2, released monthly (around end of each month).

pip install jarvis-tools
error ModuleNotFoundError: No module named 'jarvis.core.atoms'
cause Importing from jarvis.core.atoms but the version is old (<2022) or package not installed correctly.
fix
Upgrade: pip install --upgrade jarvis-tools. Also ensure you have correct import path: from jarvis.core.atoms import Atoms.
error AttributeError: 'Atoms' object has no attribute 'coords'
cause Trying to access atoms.coords directly but newer version uses atoms.cart_coords or requires utility function.
fix
Use atoms.cart_coords or from jarvis.core.utils import get_fractional_coordinates for coordinates.
error ValueError: Could not parse POSCAR file
cause Using an outdated reader for VASP files. The POSCAR parser has been updated and expects specific format.
fix
Use 'from jarvis.io.vasp.inputs import Poscar' and call Poscar.from_file('POSCAR').atoms.
error TypeError: lattice_mat must be a 3x3 list or array
cause Passing lattice vectors incorrectly (e.g., 1D array or wrong shape).
fix
Provide lattice as a list of three vectors, each a list of three floats: [[a1,a2,a3],[b1,b2,b3],[c1,c2,c3]].
breaking The 'Atoms' class was moved from jarvis.io.vasp.outputs to jarvis.core.atoms in 2022. Old imports will break.
fix Use 'from jarvis.core.atoms import Atoms' instead.
breaking The 'Graph' class is not directly importable from jarvis.core; must be imported from jarvis.core.graphs.
fix Use 'from jarvis.core.graphs import Graph'.
deprecated Functions like 'jarvis.core.utils.get_fractional_coordinates' replaced older methods on Atoms (e.g., atoms.fractional_coords). Check deprecation warnings.
fix Use jarvis.core.utils functions as needed; check documentation for new API.
gotcha The package 'jarvis-tools' should be installed with exact hyphen, not underscore (jarvis_tools). pip install jarvis_tools will fail if not found.
fix Install via 'pip install jarvis-tools'.
gotcha Many JARVIS-DFT database functions require an internet connection and may cache data in ~/.cache/atomgptlab/ by default. If you get connection errors, check network or set JARVIS_CACHE_DIR.
fix Set environment variable JARVIS_CACHE_DIR to a different path.
pip install git+https://github.com/atomgptlab/jarvis-tools.git

Create a simple atomic structure and print basic properties.

from jarvis.core.atoms import Atoms
from jarvis.core.specie import Specie

# Create an atomistic structure (diamond silicon)
coords = [[0.0, 0.0, 0.0], [0.5, 0.5, 0.5]]
elements = ["Si", "Si"]
lattice = [[0.0, 0.0, 1.0], [0.0, 1.0, 0.0], [1.0, 0.0, 0.0]]  # cubic, a=1.0

atoms = Atoms(lattice_mat=lattice, coords=coords, elements=elements)
print(atoms)
print("Lattice:", atoms.lattice_mat)
print("Number of atoms:", len(atoms))

# Convert to fractional coordinates (using utility)
from jarvis.core.utils import get_fractional_coordinates
frac = get_fractional_coordinates(atoms.coords, atoms.lattice_mat)
print("Fractional coords:", frac)