SARIAD integrates SAR datasets, anomaly detection models and pre-processing methods with Anomalib (PyTorch Lightning) and evaluates them with a common set of image- and pixel-level metrics. Every Anomalib model (Padim, Patchcore, EfficientAd, Dinomaly, ...) can be used by name next to the SAR-specific ones.
| Available | |
|---|---|
| Datasets | MSTAR, HRSID, SSDD, SAMPLE_PUBLIC, SARDet_100K (target = anomaly; normal images are generated where the dataset has none) |
| Models | SARATRX (SARATR-X masked autoencoder), YOLOAnomaly (Ultralytics backbones), PadimACE (PaDiM with adaptive cosine estimator), MSFA (filter-augmented input), plus all Anomalib models |
| Pre-processing | NLM (non-local means), MedianFilter, SARCNN (learned despeckling), Default |
| Metrics | Accuracy, precision, recall, F1, G-mean, MAR/FAR, image and pixel AUROC, pixel IoU/F1, ROC/PR curves, LaTeX comparison tables |
Details, how normal data is generated and candidate datasets/models: see the documentation (docs/).
SARIAD/
├── config/ # YAML experiment runner (run.py) and default.yaml
├── datasets/ # datamodules (Anomalib Folder subclasses): mstar, hrsid, ssdd, sample_public, sardet
├── models/ # SARATRX, YOLO, PadimACE, MFSA (MSFA), components (shared Gaussian base); lazy imports
├── pre_processing/ # NLM, MedianFilter, SARCNN, Default
└── utils/ # blob_utils (download/extract), normal_gen (normal-image generation), inf (Inferencer, Metrics)
demo/ # demo.py (run a YAML file), train.py (one model on one dataset)
docs/ # Sphinx documentation
tests/ # pytest suite (offline, CPU)
Python >= 3.13. From PyPI: pip install SARIAD.
git clone --recurse-submodules https://github.com/Advanced-Vision-and-Learning-Lab/SARIAD
cd SARIAD
pip install -e ".[dev]" # or: conda env create -f SARIAD/config/environment.yamlSARATRX and SARCNN need git submodules (--recurse-submodules, or git submodule update --init); nothing else does, and importing SARIAD works without them. Install a CUDA build of PyTorch first if you have a GPU (see the comment in SARIAD/config/environment.yaml).
Describe the datasets, models, pre-processors and repetitions in a YAML file (see SARIAD/config/default.yaml) and run it:
sariad --config SARIAD/config/default.yaml --dry-run # validate names and parameters, no downloads
sariad --config SARIAD/config/default.yaml # runs every experiment, writes metrics, plots and comparison_table.texDatasets are stored in ./datasets (override with SARIAD_DATASETS_PATH or a dataset's path argument).
Or from Python:
from anomalib.engine import Engine
from SARIAD.datasets import SSDD
from SARIAD.models import YOLOAnomaly
from SARIAD.utils.inf import Inferencer
datamodule = SSDD()
model = YOLOAnomaly(weights="yolo11n.pt")
engine = Engine()
engine.fit(model=model, datamodule=datamodule)
print(Inferencer().evaluate(model, datamodule, engine=engine))One-off runs: python demo/train.py --dataset MSTAR --model Padim --preprocessor MedianFilter.
pytest # offline, CPU, a few minutes
SARIAD_TEST_NETWORK=1 pytest tests/test_models_optional.py # also downloads YOLO weightsMIT License
This project is inspired by Anomalib and Benchmarks for Medical Anomaly Detection (BMAD).
Contributions are welcome! To contribute:
- Fork the repository on GitHub.
- Create a new branch with a descriptive name.
- Make your changes and ensure they follow the code style guidelines.
- Write unit tests for any new features or bug fixes (
tests/). - Submit a pull request with a clear description of your changes.
For major changes, please open an issue first to discuss what you'd like to change. We appreciate your contributions to improve this work!
If you use the SARIAD code, please cite the following reference using the following entry.
Plain Text:
L. Chauvin, S. Gupta, A. Ibarra and J. Peeples, "Benchmarking suite for synthetic aperture radar imagery anomaly detection (SARIAD) algorithms," in Algorithms for Synthetic Aperture Radar Imagery XXXII, vol. TBD. International Society for Optics and Photonics (SPIE), 2025, DOI: 10.1117/12.3052519
BibTex:
@inproceedings{Chauvin2025Benchmarking,
title={Benchmarking suite for synthetic aperture radar imagery anomaly detection (SARIAD) algorithms},
author={Chauvin, Lucian and Gupta, Somil, and Ibarra, Angelina, and Peeples, Joshua},
booktitle={Algorithms for Synthetic Aperture Radar Imagery XXXII},
pages={TBD},
year={2025},
organization={International Society for Optics and Photonics (SPIE)}
doi={10.1117/12.3052519}
}
If you use this dataset in your research, please cite the following paper:
@misc{mstar2025,
title = {MSTAR Public Dataset},
author = {{U.S. Air Force}},
year = {1995},
note = {Sensor Data Management System (SDMS)},
url = {https://www.sdms.afrl.af.mil/index.php?collection=mstar}
}