Registry / data / clease

clease

JSON →
library1.2.0pypypi✓ verified 85d ago

CLEASE (CLuster Expansion in Atomistic Simulation Environment) is a Python package for constructing and handling cluster expansion Hamiltonians for materials simulations, often used in conjunction with ASE. It is currently at version 1.2.0 and receives updates periodically, with the last major release in April 2024.

pip install clease
INSTALL
IMPORT
SIG · CLEASE
C
clease
datapythonv1.2.0
Install
17.7s avg
Import
Disk
426MB
Pass rate
5/ 10
Env Coverage5 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.2.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.910 runs
build_error
glibc
py 3.103.910 runs
installs and imports cleanly · install 17.7s · import 0.000s · 408MB
426MB installed
● package 426MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

ClusterCoverageChecker
from clease import ClusterCoverageChecker
from clease import CEBulk
ConvexHull
from clease import ConvexHull
from clease import CEBulk
StructureMapper
from clease import StructureMapper
from clease import CEBulk

Initializes a basic Cluster Expansion Bulk (CEBulk) object using an ASE primitive cell, defines concentrations, and sets up the cluster expansion parameters.

from ase.build import bulk from clease import CEBulk, Concentration, Settings # 1. Define primitive cell using ASE prim = bulk("Cu", "fcc", a=3.61) # 2. Define concentration for a binary system (e.g., Cu-Au) conc = Concentration(basis_elements=[["Cu", "Au"]]) # 3. Define settings for the cluster expansion settings = Settings( primitive_structure=prim, supercell=[2, 2, 2], # Supercell dimensions for mapping concentrations=[conc], max_cluster_dia=[3.0, 4.0, 5.0] # Max diameter for 2-body, 3-body, 4-body clusters ) # 4. Initialize the Cluster Expansion Bulk object ce_bulk = CEBulk(settings, verbose=False) print(f"CEBulk object initialized for {ce_bulk.name}") # Further steps involve fitting and predicting properties.
clease --version
Debug
Known issues
breakingThe main classes `CEConfig` and `CESlab` were renamed to `CEBulk` and `CEPrism` respectively.
fix
Update your imports and class instantiations: `CEConfig(...)` becomes `CEBulk(...)` and `CESlab(...)` becomes `CEPrism(...)`.
affects: >=1.1.0
breakingThe `clease.sqs` module, which provided functionality for generating Special Quasirandom Structures, has been removed.
fix
For SQS generation, migrate to the dedicated `sqsgenerator` library, which CLEASE now recommends as an external dependency.
affects: >=1.2.0
gotchaThe `max_cluster_dia` parameter in `clease.Settings` expects a list of floats (one for each cluster order), not a single float.
fix
Pass `max_cluster_dia` as a list, e.g., `max_cluster_dia=[3.0, 4.0, 5.0]` for 2-body, 3-body, and 4-body clusters respectively.
affects: All versions
Upgrade
Version history
1.2.0latest on PyPI · released Dec 22, 2025
Audit
Dependencies
numpyrequiredNumerical operations and array handling.
scipyrequiredScientific computing routines.
pandasrequiredData structures and analysis.
h5pyrequiredReading and writing HDF5 files for cluster expansion data.
dillrequiredSerialization of Python objects.
aseoptionalAtomistic Simulation Environment, commonly used for defining structures and interacting with CLEASE.
Agent activity
18 hits · last 30 days
node
16
OpenAI (training)
1
Resources
clease — pip install clease · libregistry