Skip to main content
QUICK REVIEW

[Paper Review] ReConPatch : Contrastive Patch Representation Learning for Industrial Anomaly Detection

Jeeho Hyun, SangYun Kim|arXiv (Cornell University)|May 26, 2023
Anomaly Detection Techniques and ApplicationsComputer Science5 citations
TL;DR

ReConPatch proposes a contrastive patch representation learning method for industrial anomaly detection that enhances feature discrimination using pseudo-labels from pairwise and contextual similarities, achieving state-of-the-art performance (99.72% AUROC) on MVTec AD without input augmentation, and 95.8% AUROC on BTAD.

ABSTRACT

Anomaly detection is crucial to the advanced identification of product defects such as incorrect parts, misaligned components, and damages in industrial manufacturing. Due to the rare observations and unknown types of defects, anomaly detection is considered to be challenging in machine learning. To overcome this difficulty, recent approaches utilize the common visual representations pre-trained from natural image datasets and distill the relevant features. However, existing approaches still have the discrepancy between the pre-trained feature and the target data, or require the input augmentation which should be carefully designed, particularly for the industrial dataset. In this paper, we introduce ReConPatch, which constructs discriminative features for anomaly detection by training a linear modulation of patch features extracted from the pre-trained model. ReConPatch employs contrastive representation learning to collect and distribute features in a way that produces a target-oriented and easily separable representation. To address the absence of labeled pairs for the contrastive learning, we utilize two similarity measures between data representations, pairwise and contextual similarities, as pseudo-labels. Our method achieves the state-of-the-art anomaly detection performance (99.72%) for the widely used and challenging MVTec AD dataset. Additionally, we achieved a state-of-the-art anomaly detection performance (95.8%) for the BTAD dataset.

Motivation & Objective

  • Address the domain shift between natural image pre-trained features and industrial defect data.
  • Overcome limitations of existing methods that rely on handcrafted data augmentation for contrastive learning.
  • Improve feature discriminability for subtle anomalies by learning a target-oriented representation space.
  • Enable effective anomaly detection and segmentation without extensive hyperparameter tuning or input transformations.

Proposed method

  • Utilizes a pre-trained CNN to extract patch-level features from input images.
  • Applies a learnable linear transformation to reconfigure patch features into a more discriminative space.
  • Employs a relaxed contrastive loss ($\mathcal{L}_{RC}$) to optimize feature representation using pseudo-labels.
  • Generates pseudo-labels using two similarity measures: pairwise similarity and contextual similarity among features.
  • Leverages contextual similarity to implicitly encode positional information, improving local feature alignment.
  • Trains only the linear head, preserving the pre-trained backbone and enabling efficient adaptation.

Experimental results

Research questions

  • RQ1Can contrastive learning be effectively applied to industrial anomaly detection without labeled anomaly pairs?
  • RQ2How can pseudo-labels derived from feature similarities improve representation learning in low-data regimes?
  • RQ3Can a simple linear head fine-tune pre-trained features to achieve superior anomaly detection without data augmentation?
  • RQ4To what extent does incorporating contextual similarity enhance feature discrimination for anomaly localization?
  • RQ5Does ReConPatch outperform state-of-the-art methods on benchmark datasets like MVTec AD and BTAD?

Key findings

  • ReConPatch achieves a state-of-the-art image-level AUROC of 99.72% on the MVTec AD dataset using a 480×480 input size.
  • The method outperforms PatchCore by 0.86% in anomaly segmentation AUROC (98.36% vs. 97.5%) on MVTec AD.
  • On the BTAD dataset, ReConPatch achieves 95.8% AUROC for image-level anomaly detection and 97.5% for pixel-level segmentation.
  • Visualization with UMAP confirms that ReConPatch learns a more compact and separable feature space, with normal samples clustered and anomalies pushed apart.
  • The model shows robust performance across diverse classes, including challenging ones like metal nut and leather, with accurate anomaly localization even in noisy maps.
  • The $d'$ discriminability index confirms improved separation between normal and abnormal score distributions, indicating better metric learning.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.