Abstract
Detecting anomalies in images is an important task, especially in real-timecomputer vision applications. In this work, we focus on computationalefficiency and propose a lightweight feature extractor that processes an imagein less than a millisecond on a modern GPU. We then use a student-teacherapproach to detect anomalous features. We train a student network to predictthe extracted features of normal, i.e., anomaly-free training images. Thedetection of anomalies at test time is enabled by the student failing topredict their features. We propose a training loss that hinders the studentfrom imitating the teacher feature extractor beyond the normal images. Itallows us to drastically reduce the computational cost of the student-teachermodel, while improving the detection of anomalous features. We furthermoreaddress the detection of challenging logical anomalies that involve invalidcombinations of normal local features, for example, a wrong ordering ofobjects. We detect these anomalies by efficiently incorporating an autoencoderthat analyzes images globally. We evaluate our method, called EfficientAD, on32 datasets from three industrial anomaly detection dataset collections.EfficientAD sets new standards for both the detection and the localization ofanomalies. At a latency of two milliseconds and a throughput of six hundredimages per second, it enables a fast handling of anomalies. Together with itslow error rate, this makes it an economical solution for real-worldapplications and a fruitful basis for future research.