Metadata-Version: 2.4
Name: wsidrift
Version: 0.1.0
Summary: Label-free validity monitor for computational pathology pipelines
Author-email: Abhishek Thakur <a.thakur5690@gmail.com>
License: MIT
Keywords: digital-pathology,drift-detection,model-monitoring,whole-slide-image,computational-pathology,domain-shift
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: Intended Audience :: Healthcare Industry
Classifier: License :: OSI Approved :: MIT License
Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: torch>=2.0.0
Requires-Dist: torchvision>=0.15.0
Requires-Dist: pytorch-lightning>=2.0.0
Requires-Dist: numpy>=1.24.0
Requires-Dist: scipy>=1.10.0
Requires-Dist: scikit-learn>=1.3.0
Requires-Dist: pandas>=2.0.0
Requires-Dist: openslide-python>=1.3.0
Requires-Dist: opencv-python>=4.8.0
Requires-Dist: Pillow>=10.0.0
Requires-Dist: omegaconf>=2.3.0
Requires-Dist: tqdm>=4.65.0

# wsidrift

A label-free, model-agnostic validity monitor for deployed computational pathology pipelines.

Detects when a WSI processing pipeline has drifted from its validated reference — without requiring labels or retraining.

## Architecture

```
Input WSIs ──► Feature Extractor ──► Tier 1: Input Divergence (MMD/Wasserstein)
                                  └──► Tier 2: Embedding Monitor (Mahalanobis/Energy)
                                              │
                                    Conjunction Rule ──► Validity Flag
```

- **Tier 1** — covariate shift in stain/feature distributions (label-free, assumption-light)
- **Tier 2** — model-response drift in encoder embedding space (closer to correctness)
- **Flag** — raised only when *both* tiers move in the direction that historically predicted a large generalization gap (ΔG)

## Status

Private research repository. Part of a three-paper dissertation.

## License
MIT
