Annotation-efficient image anomaly detection
AssigneeEcole Polytechnique Federale De Lausanne (Epfl)
InventorsBehzad BOZORGTABAR, Jean-Philippe THIRAN
Life of this patent
Estimating the term…
Abstract
The present invention proposes a method for detecting anomalous or out-of-distribution images in a machine learning system (1) comprising a pre-training network with a first encoder, and an anomaly detection network with a second encoder. The system is first pre-trained by training the pre-training network, and then subsequently fine-tuned by training the anomaly detection network. According to one example, during pre-training, only unlabelled training images are used, while during fine-tuning, a small fraction of labelled training images is used in addition to unlabelled training images. The method can be applied to both single and multi-domain image data.
Claims21
A computer-implemented method for detecting anomalous or out-of-distribution images in a machine learning system comprising a pre-training network comprising a first encoder, and an anomaly detection network comprising a second encoder, the method comprising:
- applying image transformations on training images to obtain modified images;
- training the pre-training network by feeding at least some of the modified images in a training image set to the pre-training network such that a similarity metric of representations of respective modified images in a respective training image set is increased when measured in a pre-training network output feature space at an output of the pre-training network with respect to the similarity metric when measured in a pre-training network input feature space to thereby obtain first encoder weight parameters;
- transferring the first encoder weight parameters to the anomaly detection network to initialise the second encoder with the first encoder weight parameters;
- initialising image clusters, which are centred at a respective cluster centre in an anomaly detection network feature space at an output of the anomaly detection network;
- training the anomaly detection network by using at least labelled training images and unlabelled training images such that the anomaly detection network is trained to map images detected as normal inside a respective image cluster, while moving images detected as anomalous away from the image clusters;
- and
- determining an anomaly score for a test image by determining a distance metric of its representation in the anomaly detection network output feature space with respect to at least the cluster centre closest to the test image.
A machine learning system for detecting anomalous or out-of-distribution images, the machine learning system comprising a pre-training network comprising a first encoder, and an anomaly detection network comprising a second encoder, the machine learning system being configured to perform operations comprising:
- apply image transformations on training images to obtain modified images;
- train the pre-training network by feeding at least some of the modified images in a training image set to the pre-training network such that a similarity metric of representations of respective modified images in a respective training image set is increased when measured in a pre-training network output feature space at an output of the pre-training network with respect to the similarity metric when measured in a pre-training network input feature space at an input of the pre-training network to thereby obtain first encoder weight parameters;
- transfer the first encoder weight parameters to the anomaly detection network to initialise the second encoder with the first encoder weight parameters;
- initialise image clusters, which are centred at a respective cluster centre in an anomaly detection network output feature space at an output of the anomaly detection network;
- train the anomaly detection network by using at least labelled training images and unlabelled training images such that the anomaly detection network is trained to map images detected as normal inside a respective image cluster, while moving images detected as anomalous away from the image clusters;
- and
- determine an anomaly score for a test image by determining a distance metric of its representation in the anomaly detection network output feature space at the output of the anomaly detection network with respect to at least the cluster centre closest to the test image.
Dependencies are inferred from the claim text.