A comprehensive Python library for analyzing and visualizing Selective plane illumination microscopy (SPIM) data, with special emphasis on dual-view SPIM (diSPIM) microscopy.
- Complete SPIM Pipeline: Data loading, ROI detection, deskewing, registration, and deconvolution
- High Performance: Built on Dask for scalable, parallel processing
- GPU Acceleration: CUDA support with CuPy for fast computation
- Interactive GUI: Full napari integration with tabbed workflow
- Modular Design: Separate core library and napari plugin
- Modern Tooling: UV-based dependency management and build system
# Install both packages
pip install pyspim napari-pyspim# Clone the repository
git clone https://github.com/matt-black/pyspim.git
cd pyspim
# Install with UV (recommended)
uv sync --extra dev
uv pip install -e packages/pyspim
uv pip install -e packages/napari-pyspimThis is a modern monorepo using UV for dependency management:
pyspim/
├── packages/
│ ├── pyspim/ # Core SPIM processing library
│ └── napari-pyspim/ # Napari plugin for GUI
├── docs/ # Documentation (MkDocs + Material)
├── examples/ # Example data and notebooks
├── examples/ # Example code, data, and scripts
└── pyproject.toml # UV workspace configuration
import pyspim
# Load and process SPIM data
data = pyspim.load_data("path/to/data.tif")
processed = pyspim.process_pipeline(data)
pyspim.save_data(processed, "output.tif")import napari
# Launch napari and load the PySPIM plugin
viewer = napari.Viewer()
# Go to Plugins → PySPIM → DiSPIM Pipeline- 📖 Full Documentation - Comprehensive guides and API reference
- 🚀 Quick Start Guide - Get up and running in minutes
- 📦 Installation Guide - Detailed setup instructions
- 🔧 API Reference - Complete function documentation
# Build documentation
just docs
# Serve documentation locally
just docs-serve- Python 3.8.1+
- UV (recommended) or pip
- CUDA-compatible GPU (optional)
# Install development environment
just install-dev
# Run tests
just test
# Format code
just format
# Run linting
just lint
# Build packages
just build
# Clean build artifacts
just cleanWe welcome contributions! Please see our Contributing Guide for details.
- numpy: Numerical computing
- dask: Parallel processing
- scikit-image: Image processing
- tifffile: TIFF file I/O
- zarr: Array storage
- cupy-cuda12x: GPU acceleration (optional)
- napari: Scientific image viewer
- npe2: Napari plugin engine
- qtpy: Qt bindings
- PyQt5: GUI framework
- Light Sheet Microscopy: Process SPIM/diSPIM data
- Multi-view Registration: Align multiple imaging views
- Deconvolution: Improve image resolution
- ROI Analysis: Focus on specific regions of interest
- Batch Processing: Process multiple datasets efficiently
This project is licensed under the GNU General Public License v3.0 (GPL-3.0) - see the License file for details.
If you use PySPIM in your research, please cite:
@software{pyspim2024,
title={PySPIM: Selective Plane Illumination Microscopy Analysis},
author={PySPIM Team},
year={2024},
url={https://github.com/matt-black/pyspim}
}- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: Full Documentation
PySPIM - Making SPIM data analysis accessible and efficient! 🔬✨