From Flow Matching to Type I Error Guarantees in Anomaly Detection
Abstract
Anomaly detection asks whether a new observation is likely to be generated by a reference distribution that characterizes normal behavior. We address this problem by learning a transport, via flow matching, that maps the reference distribution to a standard Gaussian. Once trained, this map lets us test a new sample by checking how far its transported representation lies from the Gaussian: under the reference distribution, its squared norm follows a chi-squared statistic, yielding a threshold with an explicit type 1 error rate. We further derive upper bounds that link the training loss of the underlying model to the resulting detection guarantees, showing that a well-trained model yields a test whose behavior remains close to this ideal. These results are made explicit in two cases, Gaussian and spherically symmetric reference distributions, and validated numerically. We evaluate the resulting detector on three distinct applications: detecting images that do not belong to a reference set, detecting targets in radar signals against background clutter, and classifying imbalanced biological data. Across these settings, our method is competitive against existing detectors.
est. 32% chance this paper gets accepted at ICLR 2027.
What do you think this paper will get?
All positions stay anonymous.