Skip to main content

GitHub tag (latest by date) GitHub PyPI pyversions Docs

SPyRiT

SPyRiT is a PyTorch-based deep image reconstruction package primarily designed for single-pixel imaging.

Installation

The spyrit package is available for Linux, MacOs and Windows. We recommend to use a virtual environment.

Linux and MacOs

(user mode)

pip install spyrit

(developper mode)

git clone https://github.com/openspyrit/spyrit.git
cd spyrit
pip install -e .

Windows

On Windows you may need to install PyTorch first. It may also be necessary to run the following commands using administrator rights (e.g., starting your Python environment with administrator rights).

Adapt the two examples below to your configuration (see here for the latest instructions)

(CPU version using pip)

pip3 install torch torchvision torchaudio

(GPU version using conda)

conda install pytorch torchvision torchaudio pytorch-cuda=12.4 -c pytorch -c nvidia

Then, install SPyRiT using pip:

(user mode)

pip install spyrit

(developper mode)

git clone https://github.com/openspyrit/spyrit.git
cd spyrit
pip install -e .

Test

To check the installation, run in your python terminal:

import spyrit

Get started - Examples

To start, check the documentation tutorials. These tutorials must be runned from tutorial folder (they load image samples from spyrit/images/):

cd spyrit/tutorial/

More advanced reconstruction examples can be found in spyrit-examples/tutorial. Run advanced tutorial in colab: Open In Colab

API Documentation

https://spyrit.readthedocs.io/

Contributors (alphabetical order)

  • Juan Abascal - Website
  • Thomas Baudier
  • Sebastien Crombez
  • Nicolas Ducros - Website
  • Antonio Tomas Lorente Mur - Website
  • Romain Phan
  • Fadoua Taia-Alaoui

How to cite?

When using SPyRiT in scientific publications, please cite the following paper:

  • G. Beneti-Martin, L Mahieu-Williame, T Baudier, N Ducros, "OpenSpyrit: an Ecosystem for Reproducible Single-Pixel Hyperspectral Imaging," Optics Express, Vol. 31, No. 10, (2023). https://doi.org/10.1364/OE.483937.

When using SPyRiT specifically for the denoised completion network, please cite the following paper:

  • A Lorente Mur, P Leclerc, F Peyrin, and N Ducros, "Single-pixel image reconstruction from experimental data using neural networks," Opt. Express 29, 17097-17110 (2021). https://doi.org/10.1364/OE.424228.

License

This project is licensed under the LGPL-3.0 license - see the LICENSE.md file for details

Acknowledgments

  • Jin LI for his implementation of Convolutional Gated Recurrent Units for PyTorch
  • Erik Lindernoren for his processing of the UCF-101 Dataset.

Metadata

Release files for spyrit 3.1.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 spyrit 3.1.1
File Size Uploaded
spyrit-3.1.1.tar.gz 190.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for spyrit 3.1.1
File Interpreter ABI Platform
spyrit-3.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 422.5 kB

Release files / spyrit-3.1.1.tar.gz

Download URL spyrit-3.1.1.tar.gz
Size 190.2 kB
Tags Source
SHA-256 checksum
How to use checksums
479e328956064da12ed833d0a6f1023a9c8bdc8d4135c01fe5ff42e7d2ec9d60
BLAKE2b-256 checksum
How to use checksums
9a255a909a2dc55bc9581158580d5d3e294aa0a2bb376cb752a8fe747443140f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / spyrit-3.1.1-py3-none-any.whl

Download URL spyrit-3.1.1-py3-none-any.whl
Size 232.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2ea1927788f4fa8731e6800482432daf0d094e1470b52559271d26bf306125a8
BLAKE2b-256 checksum
How to use checksums
08aaf291f4f15f6ef610f77f6d469c6509cda7598bc3c64c3593aa86ec200e72
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release history Release notifications | RSS feed

This release

3.1.1 This release

2 release files

3.1.0

2 release files

3.0.3

2 release files

3.0.2

2 release files

3.0.1

2 release files

3.0.0

2 release files

2.4.1

2 release files

2.4.0

2 release files

2.3.3

2 release files

2.3.2

2 release files

2.3.1

2 release files

2.3.0

2 release files

2.2.0

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.3.0

2 release files

1.2.0

2 release files

1.1.2

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.13.4

2 release files

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