Skip to main content

pyHyperRI

python pytorch PyPI version license CI docs

pyHyperRI is a PyTorch-based platform for developing, testing, and benchmarking radio-interferometric (RI) imaging algorithms. The current package focuses on intensity imaging, with workflows for both monochromatic and distributed hyperspectral reconstruction.

The package is installed as pyHyperRI and imported in Python as hyri.

Key Features

  • Modular components for RI algorithm development: measurement operators, regularisers, denoisers, and optimisers.
  • Intensity imaging workflows for monochromatic and hyperspectral data.
  • Implemented algorithms: uSARA, AIRI, cAIRI, Hyper-uSARA, and HyperAIRI.
  • PyTorch-native device support across CPU, CUDA, MPS, and XPU where available.
  • Distributed hyperspectral imaging through torch.distributed.
  • NUFFT measurement operators with FINUFFT and TorchKbNUFFT backends.

Installation

Install PyTorch first by following the official PyTorch installation guide, because the correct build depends on the operating system and target device.

Then install pyHyperRI:

pip install pyHyperRI

If CUDA devices are available, install the CUDA optional dependency group:

pip install "pyHyperRI[cuda]"

Measurement Set dependency is available through the ms optional dependency group:

pip install "pyHyperRI[ms]"

Use this option mainly on Linux. On other systems, the prerequisite casacore usually needs to be installed separately before installing python-casacore. See the documentation for detailed installation guide.

For a source install:

git clone https://github.com/ChaoTang0330/py-hyper-ri.git
cd py-hyper-ri
pip install -e .

For development on Linux with CUDA devices, install all optional dependencies:

pip install -e ".[all]"

To verify the installation, run

hyri --help

We provide two Docker image variants with CUDA 12.8: development and runtime. The development image includes editable source code, all optional dependencies, tests, notebooks and documentation tools. The runtime image provides the installed package with CUDA and Measurement Set dependencies for running imaging workflows. Both images are available from GitHub Container Registry. See the Docker Images section of the installation guide for image details and customisation, and Run in a Container for container usage.

Minimal Example

Example measurements are available in the repository's 3c353_sim_vla_meas_hs folder. Place this folder under ./data in your working directory, then run:

hyri imaging \
  --algorithm usara \
  --superresolution 1.5 \
  --data_file ./data/3c353_sim_vla_meas_hs

Use hyri imaging --help to inspect available command-line options.

Documentation

Full documentation: pyHyperRI documentation.

The documentation covers the input data format, general usage, configuration files, tutorials, and the API reference.

To build the documentation locally, the packages under the dependency group docs are required.

pip install -e ".[docs]"
make docs

Citation

If you use pyHyperRI, please cite this software repository using the metadata in CITATION.cff. If you use specific implemented methods, please also cite the relevant method papers listed in the documentation.

License

pyHyperRI is distributed under the BSD 3-Clause License.

Dependencies

pyHyperRI builds on several external packages. The full dependency list is declared in pyproject.toml. Main dependencies and their associated references are listed below.

Package Reference
Astropy Astropy Collaboration et al., The Astropy Project: Sustaining and Growing a Community-oriented Open-source Project and the Latest Major Release, The Astrophysical Journal, 2022.
casacore and python-casacore van Diepen, Casacore Table Data System and its use in the MeasurementSet, Astronomy and Computing, 2015.
FINUFFT and cuFINUFFT Barnett et al., A Parallel Nonuniform Fast Fourier Transform Library Based on an Exponential of Semicircle Kernel, SIAM Journal on Scientific Computing, 2019; Shih et al., cuFINUFFT: a load-balanced GPU library for general-purpose nonuniform FFTs, IPDPSW, 2021.
h5py Andrew Collette and contributors, h5py, BSD 3-Clause licensed software, 2008.
NumPy Harris et al., Array programming with NumPy, Nature, 2020.
onnx2torch ENOT developers et al., onnx2torch, Apache-2.0 licensed software, 2021.
PyTorch Paszke et al., PyTorch: An Imperative Style, High-Performance Deep Learning Library, NeurIPS 2019.
PyTorch Wavelet Toolbox Wolter et al., ptwt - The PyTorch Wavelet Toolbox, Journal of Machine Learning Research, 2024.
scikit-image van der Walt et al., scikit-image: image processing in Python, PeerJ, 2014.
SciPy Virtanen et al., SciPy 1.0: fundamental algorithms for scientific computing in Python, Nature Methods, 2020.
TorchKbNUFFT Muckley et al., TorchKbNufft: A High-Level, Hardware-Agnostic Non-Uniform Fast Fourier Transform, ISMRM Workshop on Data Sampling & Image Reconstruction, 2020.

Metadata

Release files for pyHyperRI 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyHyperRI 1.0.1
File Size Uploaded Provenance Actions
pyhyperri-1.0.1.tar.gz 74.3 MB With provenance Details for pyhyperri-1.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pyHyperRI 1.0.1
File Interpreter ABI Platform Actions
pyhyperri-1.0.1-py3-none-any.whl Python 3 none any Details for pyhyperri-1.0.1-py3-none-any.whl

Total release size: 148.6 MB

Release files / pyhyperri-1.0.1.tar.gz

Download URL pyhyperri-1.0.1.tar.gz
Size 74.3 MB
Tags Source
SHA-256 checksum
How to use checksums
cd1ab3d82a6203b4379aa48ba0ce21d7e9903b4bf754febe8c7dec09c3cac91b
BLAKE2b-256 checksum
How to use checksums
1cc2c39f9f9dc74936bdce4a8a487bbbc43a4d90a4a784a9308b6ab3adc329b8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 23, 2026.

Transparency log

Release files / pyhyperri-1.0.1-py3-none-any.whl

Download URL pyhyperri-1.0.1-py3-none-any.whl
Size 74.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
d9d0bf1f091e9bce67cf490f184d0a9d3083b4f37cd0a2884bed42d893ca677a
BLAKE2b-256 checksum
How to use checksums
785f5217043552479d61dc602fd7f4d295b1b35ba8c3572125e7503885bebef7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 23, 2026.

Transparency log

Security for pyHyperRI 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for pyhyperri-1.0.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 23, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page