
StainX: Making Stain Normalization Scale
Color variation across histopathology slides remains one of the most stubborn sources of noise in computational pathology. Different scanners, staining protocols, and laboratories produce images that look systematically different even when the underlying tissue is similar. This batch effect degrades the performance of AI models, especially foundation models trained across multiple institutions.
Classical stain normalization methods (Histogram Matching, Macenko, Reinhard) are training-free, interpretable, and effective. The problem is speed. Existing implementations process images sequentially or fail to fully exploit modern GPUs, making them impractical for the tens of thousands of tiles that make up large whole-slide image cohorts.