Skip to main content

Quantitative 3D analysis of volume electron microscopy data with ML and classical image processing

Project description

sphero-vem

Python CI codecov Ruff

Python library for quantitative analysis of volumetric electron microscopy (vEM) data.

sphero-vem was developed for the end-to-end analysis pipeline described in:

Bottone et al., 3D Reconstruction of Nanoparticle Distribution in Tumor Spheroids with Volume Electron Microscopy, [Preprint: https://doi.org/10.64898/2026.04.17.719153]

While the library was originally developed for SBF-SEM data of nanoparticle-loaded tumor spheroids, the individual components are designed to be reusable for other vEM datasets and workflows.

Capabilities

  • Denoising: self-supervised Noise2Void via CAREamics on large zarr volumes
  • Registration: intensity-based pairwise slice alignment with multi-resolution PyTorch optimization
  • Segmentation: fine-tuning and inference with Cellpose-SAM for cells and nuclei; empirical Bayes approach for nanoparticles
  • Shape analysis: 3D morphological descriptors via signed distance functions and mesh-based curvature (mean curvature, curvedness, shape index, fractal dimension)
  • Spatial analysis: nanoparticle-to-nucleus distance quantification per cell
  • Data management: zarr-native I/O with OME-NGFF multiscale support and processing metadata tracking

Installation

Clone the repository and install with Poetry:

git clone https://github.com/dv-bt/sphero-vem.git
cd sphero-vem
poetry install           # CPU and limited GPU acceleration
poetry install -E cuda   # with full CUDA 12.x GPU acceleration (Linux/Windows only)

Documentation

Full documentation is available on the official website.

Requirements

GPU acceleration

PyTorch-based stages (denoising, registration, Cellpose segmentation) support GPU execution via PyTorch's native device management, including CUDA and MPS (Apple Silicon), and require no additional dependencies.

Array operation stages (nanoparticle segmentation, shape analysis, spatial analysis) additionally support CUDA acceleration via CuPy and CuCIM, installed with the cuda optional dependency group above. GPU acceleration is handled automatically with a custom orchestrator.

Dataset and model weights

The annotated SBF-SEM dataset used to develop this pipeline is available at BioImage Archive (https://doi.org/10.6019/S-BIAD3263). Fine-tuned Cellpose-SAM model weights are available on Zenodo (https://doi.org/10.5281/zenodo.19616546).

Citation

If you use this library, please cite the accompanying paper:

@article {Bottone2026,
	author = {Bottone, Davide and Gerken, Lukas RH and Habermann, Sebastian and Mateos, Jose Maria and Lucas, Miriam S and Riemann, Johannes and Fachet, Melanie and Resch-Genger, Ute and Kissling, Vera M and Roesslein, Matthias and Gogos, Alexander and Herrmann, Inge K},
	title = {3D Reconstruction of Nanoparticle Distribution in Tumor Spheroids with Volume Electron Microscopy},
	year = {2026},
	doi = {10.64898/2026.04.17.719153},
	eprint = {https://www.biorxiv.org/content/early/2026/04/21/2026.04.17.719153},
}

License

See LICENSE for details.

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

sphero_vem-0.1.0.tar.gz (76.9 kB view details)

Uploaded Source

Built Distribution

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

sphero_vem-0.1.0-py3-none-any.whl (91.8 kB view details)

Uploaded Python 3

File details

Details for the file sphero_vem-0.1.0.tar.gz.

File metadata

  • Download URL: sphero_vem-0.1.0.tar.gz
  • Upload date:
  • Size: 76.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for sphero_vem-0.1.0.tar.gz
Algorithm Hash digest
SHA256 1c5bc3abcd4a5c46f23decade4cf9e3bf81ebf42556723a6d98367fbac38ffd6
MD5 15b7cd996b6407a9109806c901182ee0
BLAKE2b-256 6523cec803838aac0e14d6c3ad5dedf5446f465bacef37e34268229e7ab5adde

See more details on using hashes here.

Provenance

The following attestation bundles were made for sphero_vem-0.1.0.tar.gz:

Publisher: release.yml on dv-bt/sphero-vem

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sphero_vem-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: sphero_vem-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 91.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for sphero_vem-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4b0276a02404cf09caf744f454bc8871b956202bf997351d7a5991936b0d1194
MD5 2f0a6193b785df87d41299943250a4cc
BLAKE2b-256 c9a9aee1d66e7925124b38e1c6684d1e0effbb2bc5a605d215c808110c09f454

See more details on using hashes here.

Provenance

The following attestation bundles were made for sphero_vem-0.1.0-py3-none-any.whl:

Publisher: release.yml on dv-bt/sphero-vem

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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