quantEM requires Python 3.11 or newer.
Install from PyPI¶
The released package is available on PyPI as quantem:
pip install quantemTo include the optional interactive Jupyter widgets:
pip install "quantem[widgets]"GPU support¶
quantEM uses PyTorch for computation. The default pip install pulls in a torch build appropriate for your platform:
Linux with NVIDIA GPUs: the default PyPI wheels include CUDA support. If you need a specific CUDA version, follow the PyTorch installation selector before installing quantEM.
Apple silicon (macOS): the default wheels support the MPS backend; no extra steps are needed.
CPU only: everything works on CPU; it is simply slower for the larger reconstructions.
Device selection is described in GPU configuration.
Developer install¶
Development uses uv:
git clone https://github.com/electronmicroscopy/quantem.git
cd quantem
uv syncuv sync --all-packages also installs the quantem.widget workspace package. Full developer setup (pre-commit, ruff, dependency management) is described in Contribute and in CONTRIBUTORS.md.
Verify the installation¶
import quantem
print(quantem.__version__)