StainX: GPU-accelerated batch stain normalization for computational pathology at scale
Moustafa, S.; Zheng, Y.; Rendeiro, A. F.
Show abstract
Stain normalization reduces color variability in histopathology whole-slide images, but cohort-scale pipelines lack fused multi-image batch transforms for classical methods. We present StainX, a GPU-accelerated batch stain normalization framework built around a two-stage fit/transform interface. It implements histogram matching, Macenko, and Reinhard normalizers through a portable PyTorch backend and an optional CUDA backend that fuses per-pixel operations for batch throughput. On NVIDIA GPUs, the fused CUDA path outperforms the torch CPU backend by 168x, 70x, and 48x for Reinhard, histogram matching, and Macenko respectively, and exceeds the fastest GPU peers by 7-8x (Reinhard) and 2x (Macenko) at comparable accuracy. StainX also provides user-selectable precision modes, a documented Python API, continuous integration testing, and online documentation. Source code available at https://github.com/rendeirolab/stainx, and documentation at https://stainx.readthedocs.io. Implemented in Python. Runs on Linux, macOS, and Windows.
Matching journals
The top 5 journals account for 50% of the predicted probability mass.
Similar papers in this journal
- ROSIE: AI generation of multiplex immunofluorescence staining from histopathology images 94%
- Segmenting functional tissue units across human organs using community-driven development of generalizable machine learning algorithms 93%
- Features fusion or not: harnessing multiple pathological foundation models using Meta-Encoder for downstream tasks fine-tuning 92%
Similar papers in this journal
- Sardine: a modular framework for developing data acquisition and near real-time analysis applications 93%
- FalseColor-Python: a rapid intensity-leveling and digital-staining package for fluorescence-based slide-free digital pathology 93%
- SAMCell: Generalized Label-Free Biological Cell Segmentation with Segment Anything 92%
"Similar papers" are the closest papers from that journal in the model's embedding space. They show what the match is built on, but the ranking comes mostly from a classifier over the whole training set, not from these examples alone.