Skip to main content

A toolbox for X-ray holo-tomography in Python

Project description

HoToPy - A toolbox for X-ray holo-tomography in Python

HoToPy

Documentation

Check out the online documentation at: https://irp.pages.gwdg.de/hotopy/reference.

Installation

We recommend to install HoToPy in a dedicated Python virtual environment, which can be created using uv venv or vanilla Python venv python3 -m venv.

pip installation

HoToPy can be installed through pip by running

pip install hotopy

for a basic HoToPy installation.

Tomography backend

The base installation of HoToPy does not contain a tomography backend. If you intend to use the tomographic functions in hotopy.tomo, you need to install the ASTRA toolbox as tomographic backend.

It can be conveniently installed through the optional dependency tomo of HoToPy by running:

pip install hotopy[tomo]

Alternative installation methods of the ASTRA toolbox can be found in its documentation.

PyTorch CUDA version

uv

You can use Astral's uv (an extremely fast Python package and project manager) built-in features to install different versions of CUDA backends. Consult their uv PyTorch integration documentation for details.

For example, you can explicitly request PyTorch with CUDA-13.0 with:

uv pip install hotopy --torch-backend=cu130

Replace cu130 with your desired version, e.g. cpu, cu126, cu128, etc. See available targets. Also, an automatic PyTorch backend selection is possible with auto.

pip

We strongly recommend using the uv tool, see above.

For pip-based installation, you can use the index URLs provided by the PyTorch project, see their Getting started documentation. For example, you can install HoToPy with PyTorch using CUDA-13.0 by running:

pip install hotopy --index-url https://download.pytorch.org/whl/cu130 --extra-index-url https://pypi.org/simple/

Replace cu130 with your desired version, e.g. cpu, cu126, cu128, etc. See available targets.

Source installations

You can also install bleeding-edge versions of HoToPy by cloning the repository.

git clone https://gitlab.gwdg.de/irp/hotopy.git
cd hotopy
uv pip install '.[tomo,dev]'

Here, the optional dependencies for tomography and development (dev) are included in the installation. You may add the --editable flag to the installation, for an editable development deployment.

Getting started

You can find examples in the dedicated HoToPy-Examples repository.

Paper & Citation

If you use HoToPy, please cite the paper HoToPy: a toolbox for X-ray holo-tomography in Python

@article{Lucht2025_hotopy,
    author = "Lucht, Jens and Meyer, Paul and Lohse, Leon Merten and Salditt, Tim",
    title = "{{\it HoToPy}: a toolbox for X-ray holo-tomography in Python}",
    journal = "Journal of Synchrotron Radiation",
    year = "2025",
    volume = "32",
    number = "6",
    pages = "1586--1594",
    month = "Nov",
    doi = {10.1107/S1600577525008550},
    url = {https://doi.org/10.1107/S1600577525008550},
    keywords = {X-ray imaging, phase retrieval, computed tomography, phase contrast, holography},
}

Project details


Download files

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

Source Distribution

hotopy-0.25.1.tar.gz (86.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hotopy-0.25.1-py3-none-any.whl (104.3 kB view details)

Uploaded Python 3

File details

Details for the file hotopy-0.25.1.tar.gz.

File metadata

  • Download URL: hotopy-0.25.1.tar.gz
  • Upload date:
  • Size: 86.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Rocky Linux","version":"9.8","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for hotopy-0.25.1.tar.gz
Algorithm Hash digest
SHA256 c8df32a0ffba9d772b62a386b8ac444a4647748fbee286a113841d4d56073b81
MD5 de75819187c9d36ec70e3ba4994ca063
BLAKE2b-256 9747357e96491ef81551b0d2b8898dac8905f0524c9e84de54b429b0c956751c

See more details on using hashes here.

File details

Details for the file hotopy-0.25.1-py3-none-any.whl.

File metadata

  • Download URL: hotopy-0.25.1-py3-none-any.whl
  • Upload date:
  • Size: 104.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Rocky Linux","version":"9.8","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for hotopy-0.25.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4c8f03a3561d953552472e2a306b278743b75d0ecf9d88ef916625cf0077d262
MD5 c3178b9195aec2db036c03e704898c87
BLAKE2b-256 0629e2c8983586c75a2a1a83f494e2e6c29fbf6b7a3f20412565341acfa8da84

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page