Next Article in Journal
Molecular Layer Doping ZnO Films as a Novel Approach to Resistive Oxygen Sensors
Previous Article in Journal
A Zero-Shot Framework for Low-Resource Relation Extraction via Distant Supervision and Large Language Models
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

DualAD: Exploring Coupled Dual-Branch Networks for Multi-Class Unsupervised Anomaly Detection

by
Shiwen He
1,2,
Yuehan Chen
1,
Liangpeng Wang
2,
Wei Huang
3,
Rong Xu
1 and
Yurong Qian
4,*
1
School of Computer Science and Engineering, Central South University, Changsha 410083, China
2
Purple Mountain Laboratories, Nanjing 210096, China
3
School of Computer Science and Information Engineering, Hefei University of Technology, Hefei 230601, China
4
School of Software, Xinjiang University, Urumqi 830049, China
*
Author to whom correspondence should be addressed.
Electronics 2025, 14(3), 594; https://doi.org/10.3390/electronics14030594
Submission received: 3 January 2025 / Revised: 28 January 2025 / Accepted: 31 January 2025 / Published: 2 February 2025
(This article belongs to the Section Artificial Intelligence)

Abstract

:
Anomaly detection (AD) is crucial in various domains such as industrial inspection, medical diagnosis, and video surveillance. Previous advancements in unsupervised AD often necessitated training separate models for different objects, which can be inefficient when dealing with diverse categories in real-world scenarios. This paper addresses the recently proposed task of multi-class unsupervised anomaly detection (MUAD), which is more practical and challenging. We begin by reviewing the first MUAD framework, UniAD, and analyzing the characteristics of end-to-end feature reconstruction networks that can adapt to various backbone architectures. Building on these insights, we introduce a novel MUAD framework called DualAD. Our approach is based on the innovative design of a Coupled Dual-Branch Network (CDBN), which integrates a Wide–Shallow Network (WSN) with a Narrow–Deep Network (NDN), leveraging the strengths of both to achieve superior performance. We explore a fully transformer-based homogeneous design for the CDBN and introduce a more lightweight heterogeneous CDBN design that integrates a transformer with a Memory-Augmented Multi-Layer Perceptron (MMLP). Experimental results on the MVTec AD and VisA datasets demonstrate that DualAD outperforms the recent state-of-the-art methods and exhibits robust performance across various pre-trained backbone architectures.

1. Introduction

AD is a critical issue in the computer vision community, with extensive applications in industrial quality inspection, medical diagnosis, video surveillance, and other domains. In real-world scenarios, anomaly data are usually sparse and exhibit diverse patterns, posing a challenge for manually collecting adequately annotated anomaly samples. Therefore, current research in this field mainly focuses on unsupervised methods. As shown in Figure 1, in an unsupervised setting, AD models are trained on normal images to learn their distribution, aiming to detect and localize anomalies that deviate from it. Most existing unsupervised anomaly detection (UAD) methods are based on a single-class setting, where separate AD models are trained for each class. However, considering the diversity of categories and subtypes within individual categories in real-world anomaly detection scenarios, along with the significant memory and time consumption associated with running multiple models, this separate setting may be impractical. Therefore, a more realistic solution is to train a unified model capable of detecting anomalies across multiple classes of objects.
Recent UAD methods primarily rely on embedding and reconstruction techniques. Embedding-based approaches [1,2,3] typically utilize backbones pre-trained on ImageNet [4] to extract patch-level image features, constructing a prior distribution of normality. Reconstruction-based methods often follow an encoder–decoder framework to reconstruct input data. A prevalent approach combines reconstruction with embedding to perform feature-level reconstructions, which can be categorized into end-to-end reconstruction [5] and multi-stage reconstruction [6] depending on the strategy. While reconstruction-based methods are highly practical, as they detect anomalies by identifying anomalies in reconstruction errors without requiring complex training constraints or tricks, they suffer from the problem of the “identical shortcut” [5], where the model may learn tricks to reconstruct anomalies effectively. To mitigate this, enhancement strategies such as pseudo-anomalies [7] and memory mechanisms [8] are often introduced.
MUAD was first introduced in UniAD [5], which employs a pre-trained feature extractor along with a transformer-based [9] end-to-end feature reconstruction network. While UniAD has certain advantages, it relies on EfficientNet-b4 [10] as the feature extractor, which exhibits significantly lower-dimensional features compared to other commonly used pre-trained backbones, such as the ResNet series [11]. When using backbones with higher-dimensional features, significant dimensionality reduction can lead to severe and irrecoverable information loss, thereby constraining the accuracy of AD. To mitigate this, increasing the transformer’s embedding dimension is often necessary. However, the expansion of network capacity does not guarantee improved detection capabilities and can even lead to significant performance degradation. As shown in Figure 2, this issue arises when using WideResNet50 [11] (which extracts 1792-dimensional feature embeddings) instead of EfficientNet-b4’s 272-dimensional embeddings. The applicability of end-to-end reconstruction models across different feature extractor architectures remains largely unexplored.
Figure 1. (a) Task setup for unsupervised anomaly detection (UAD). During training, only normal sample images are used to train the model. In the testing phase, the model is tasked with distinguishing between normal and anomalous samples and identifying the location of any anomalies. (b) Single-class unsupervised anomaly detection (SUAD): a separate model is trained for each class to detect anomalies specific to that class. (c) Multi-class unsupervised anomaly detection (MUAD): a single unified model is trained to perform anomaly detection across multiple object classes (Figure created by the authors. Sample images are from the MVTec AD [12] dataset).
Figure 1. (a) Task setup for unsupervised anomaly detection (UAD). During training, only normal sample images are used to train the model. In the testing phase, the model is tasked with distinguishing between normal and anomalous samples and identifying the location of any anomalies. (b) Single-class unsupervised anomaly detection (SUAD): a separate model is trained for each class to detect anomalies specific to that class. (c) Multi-class unsupervised anomaly detection (MUAD): a single unified model is trained to perform anomaly detection across multiple object classes (Figure created by the authors. Sample images are from the MVTec AD [12] dataset).
Electronics 14 00594 g001
To address the aforementioned issues, we propose a novel MUAD framework, namely DualAD. We begin by revisiting the UniAD framework, investigating how the transformer’s width and depth affect MUAD performance. Our findings indicate that a wider and shallower reconstruction network outperforms the default UniAD configuration in overall performance, while a deeper reconstruction network excels at capturing structural and semantic features. Based on these insights, we propose CDBN, which integrates a WSN and an NDN. Drawing inspiration from multi-head attention [9] and multi-stage feature fusion [6], the CDBN seamlessly integrates these two networks into a unified end-to-end reconstruction model, leveraging their strengths to achieve enhanced overall performance. Expanding on UniAD, we present a homogeneous CDBN design entirely based on the transformer. Additionally, we explore a more lightweight heterogeneous CDBN design that combines a transformer with an MMLP. Finally, we conduct extensive experiments on two well-known UAD public benchmark datasets, MVTecAD [12] and VisA [13], comparing our framework to recent state-of-the-art methods. The results confirm the superior performance of our framework, as well as its versatility across different pre-trained backbone architectures.
The main contributions of this paper are summarized as follows:
  • We propose the DualAD, which tackles multi-class unsupervised anomaly detection tasks and explores a novel end-to-end feature reconstruction framework (see Section 3.3).
  • We introduce the CDBN, which integrates a WSN and an NDN, leveraging their combined strengths to achieve superior overall performance (see Section 3.3.2).
  • We present a homogeneous CDBN design entirely based on the transformer and explore a more lightweight heterogeneous design that combines a transformer with an MMLP (see Section 3.3.3).
  • We conduct extensive experiments on the popular MVTec AD and VisA benchmark datasets, comparing our framework to recent state-of-the-art methods. The results demonstrate the superior performance of DualAD and its effectiveness across different pre-trained backbones (see Section 4).
The remainder of this paper is organized as follows: Section 2 reviews related work on UAD and recent advancements in MUAD. Section 3 outlines the materials and methods, including the task definition and setups, a revisit of transformer-based MUAD, and a detailed description of our proposed method, and the experimental setups. Section 4 presents the experimental results, offering quantitative comparisons with state-of-the-art methods on two public benchmark datasets, along with ablation studies. Section 5 discusses the key findings and limitations of our work, while Section 6 provides conclusions and highlights potential directions for future research.

2. Related Work

This section provides a comprehensive overview of existing research in UAD, with a particular focus on embedding-based and reconstruction-based methods, as well as recent developments in MUAD. We first discuss general approaches in UAD and then shift to more specific advancements in MUAD. The section is organized as follows: Section 2.1 covers general UAD methods, highlighting both embedding-based and reconstruction-based techniques, while Section 2.2 reviews the evolution of MUAD, detailing key contributions from prominent works.

2.1. Unsupervised Anomaly Detection

Embedding-based methods focus on modeling the deep feature representations of normal samples. Early efforts, such as those by Ruff et al. [14] and Yi et al. [15], extended classical one-class classification techniques like Support Vector Data Description (SVDD) [16] to deep features. Recent research tends to utilized features extracted from networks pre-trained on ImageNet [4] to construct the prior distribution of normal samples, often in conjunction with other methodologies. For example, the following:
(1)
Memory-based methods. These methods attempt to build prototype banks of pre-trained features for normal samples [1,17,18,19,20,21] and detect anomalies by matching against these normal templates. Roth et al. [1] directly compute the distance between the test sample and the most similar normal feature template to estimate the degree of anomaly. Liu et al. [19] and Gu et al. [20] enhance the input’s normality by matching with normal features. Zhang et al. [21] estimate the anomalous region by calculating the residual between the sample and the normal template, assisting the segmentation network’s decision. These methods are conceptually simple and effective. However, the cost of building prototype banks and the detection cost both increase with the number of categories, which limits their scalability in multi-class settings.
(2)
Normalizing flow-based methods. These methods seek to map the pre-trained features of normal samples to simpler probability distributions [2,22,23,24,25], such as multivariate Gaussian distributions. Rudolph et al. [22] first introduced normalizing flows for density estimation of multi-scale image features. However, this method primarily focuses on image-level anomaly detection. Gudovskiy et al. [23] enhanced anomaly localization by using conditional normalizing flows and introducing 2D hard positional encoding. Yu et al. [2] proposed a 2D normalizing flow and employed a vision transformer as the feature extractor for the first time. Lei et al. [25] introduced an anomaly localization paradigm based on normalizing flows and latent template comparison. These methods provide accurate density estimation for data, allowing for effective anomaly detection. However, they generally require significant computational resources for training, especially when dealing with high-dimensional data, leading to substantial training time and computational costs. Furthermore, these methods assume that the distribution of normal data is known and that the data must adhere to certain distributional properties. For more complex data distributions, the performance of the model may be affected.
(3)
Knowledge Distillation-based methods. These methods employ a pre-trained network as a teacher model, training a student model to learn its representation of normal samples [3,26,27,28], with anomalies being identified based on the output differences between the teacher and student models. Bergmann et al. [3] first utilized knowledge distillation for anomaly detection, which ensembles several student models trained on normal data at different scales. Wang et al. [27] introduced a pyramid feature matching mechanism between the teacher and student models, further improving anomaly localization efficiency and accuracy. Zhang et al. [28] proposed a denoising teacher-student network paradigm that enhanced the constraints on anomalous data. These methods are based on the assumption that a student network constrained only on the outputs of normal samples during training will generate different feature representations for anomalous samples compared to the teacher network. However, in practice, this assumption does not always hold true.
Reconstruction-based methods typically follow an encoder–decoder architecture and are based on the assumption that models trained solely on normal images cannot accurately reconstruct unseen anomalies, such as the surface staining of pills or the placement anomalies of transistors, as shown in Figure 3. These anomalies often differ significantly from their normal patterns. As a result, anomalies can be identified by comparing reconstruction errors with those of normal samples.
(1)
Image-level methods. These methods use the RGB pixels of the original image for reconstruction.The most basic approach involves autoencoders (AEs) [29,30,31], which map input images to latent space through an encoder and then reconstruct them via a decoder. The reconstruction is optimized by minimizing the difference between the original input and the output, typically using loss functions like Mean Squared Error (MSE). While these methods are conceptually simple, they face challenges in handling more complex scenarios. To improve reconstruction performance, generative models have been introduced. Variational autoencoders (VAEs) [32,33] learn the latent probabilistic distribution of the data, with the encoder outputting distribution parameters instead of a fixed latent vector. The loss function incorporates Kullback–Leibler (KL) divergence as a regularization term to constrain the latent space distribution. Generative Adversarial Networks (GANs) [34,35] employ adversarial training between a generator and a discriminator, where the generator learns the distribution of normal data, and the discriminator identifies outliers as potential anomalies. Diffusion-based methods [36,37,38] learn the data distribution through a series of noise addition and denoising steps to reconstruct inputs.
(2)
Feature-level methods. With the increasing popularity of embedding-based methods that leverage pre-trained networks for feature extraction, recent studies have introduced feature-level reconstruction techniques. These methods aggregate outputs from multiple stages of pre-trained networks and utilize different strategies for feature reconstruction. Methods by You et al. [5] and Lu et al. [39] employ end-to-end matching approaches, using an AE to reconstruct aggregated pre-trained features in a manner similar to image reconstruction. Meanwhile, Deng et al. [6], Zhang et al. [40], and He et al. [41] adopt multi-stage matching strategies, aggregating reconstruction differences between intermediate layers across multiple scales of the pre-trained network and decoder to assess anomaly severity.
Reconstruction-based methods are relatively easy to train and highly practical, but they are prone to the “identical shortcut” problem [5], where the model may learn techniques that effectively reconstruct anomalies, leading to ambiguous decision boundaries. To mitigate this issue, various enhancement strategies have been employed. Some methods augment reconstruction networks with memory mechanisms. Gong et al. [8] introduced the memory mechanism by adding a learnable memory module between the encoder and decoder. This module can be viewed as a dictionary organized in a matrix form, with each vector corresponding to a “word” in the dictionary. During training, the matrix parameters are jointly optimized with the AE to learn the feature patterns of normal data. The memory module is designed to reorganize abnormal features into normal ones, thereby improving the normality of the decoder’s output. Many subsequent methods have extended this design. For instance, Liu et al. [42] extended the memory module to multi-level features, while Hou et al. [43] used block-wise queries to prevent poor reconstruction of anomalous features due to limited anomaly patterns.
(3)
Enhancement strategies. Reconstruction-based methods are easy to train and demonstrate strong practicality; however, they are prone to the “identical shortcut” problem [5], where the model may learn specific techniques that effectively restore anomalies, resulting in ambiguous decision boundaries. To mitigate this issue, various enhancement strategies are employed. Some methods augment reconstruction networks with memory mechanisms. Gong et al. [8] introduce the memory mechanism by adding a learnable memory module between the encoder and decoder. This module can be viewed as a dictionary organized in a matrix form, with each vector corresponding to a “word” in the dictionary. During training, the matrix parameters are jointly optimized with the AE to learn the feature patterns of normal data. The memory module is designed to reorganize anomalous features into normal ones, thereby improving the normality of the decoder’s output. Many subsequent methods have extended this design. For instance, Liu et al. [42] extend the memory module to multi-level features, while Hou et al. [43] use block-wise queries to prevent poor reconstruction of anomalous features due to limited anomaly patterns. Furthermore, pseudo-anomalies can be added to the normal data for self-supervised training, helping to better model the normal distribution. Li et al. [44] generate anomalous images by randomly selecting a block from a normal image and pasting it into another region. Wyatt et al. [36] and Tien et al. [45] generate block-level image anomalies using simplex noise. Zavrtanik et al. [7,46] synthesize more realistic, shape-random image anomalies by combining Perlin noise with the Describable Textures Dataset [47]. In addition to adding pseudo-anomalies to the original images, Liu et al. [48] and You et al. [5] introduce anomalies at the feature level by adding Gaussian noise.

2.2. Multi-Class Unsupervised Anomaly Detection

Most existing unsupervised anomaly detection (UAD) methods are based on a single-class setting, where separate detection models are trained for each class. However, considering the diversity of categories in real-world scenarios and the variations among different subtypes within a single category, along with the significant memory and time consumption required to operate multiple models, this separate approach may not be practical. Therefore, a more feasible solution is to train a unified model capable of detecting anomalies across multiple object classes. The first MUAD framework, UniAD, was introduced by You et al. [5], who developed a unified model based on transformers [9] for end-to-end feature reconstruction. Subsequent research has advanced this framework: Lu et al. [39] integrated the VQ-Layer [49] into the transformer, while Jiang et al. [50] reduced inter-class interference through implicit neural representations [51] and class prompts. Other approaches have focused on exploring different reconstruction network architectures: Zhao et al. [52] proposed a CNN-based MUAD framework, He et al. [38] introduced a diffusion model, and Zhang et al. [40] proposed ViTAD, a multi-stage feature reconstruction framework entirely based on vision transformers. Furthermore, Ruan et al. [53] introduced MambaAD, which was the first to incorporate Mamba [41] into MUAD. However, these methods often rely on specific feature extractors, such as UniAD’s dependence on EfficientNet [10] and ViTAD’s reliance on vision transformers [54] as feature extractors. The applicability of reconstruction models across different feature extractor architectures remains largely unexplored.

3. Materials and Methods

3.1. Task Definition and Setups

Unsupervised Anomaly Detection. Image AD aims to identify samples or local patterns that significantly deviate from normal data. In the context of UAD, as illustrated in Figure 1a, the detection model is trained solely on normal images and is tasked with distinguishing between normal and anomalous samples during the testing phase, as well as identifying the locations of anomalies within the anomalous images. Depending on how the dataset is utilized, UAD can be categorized into two configurations:
Single-class Unsupervised Anomaly Detection. Under the SUAD setting, as illustrated in Figure 1b, a separate model is trained for each individual class to detect anomalies specific to that class. Formally, assume an AD dataset contains N classes, denoted as C = { C 1 , C 2 , , C N } , each experiment focuses exclusively on a sub-dataset X C i = { X C i Train , X C i Test } corresponding to a single class C i C , where X C i Train comprises all normal images available during the training phase ( x X C i Train : y x = 0 ), with  y x { 0 , 1 } denoting if an image x is normal 0 or anomalous 1, and  X C i Test is defined as the set of samples at test time, which includes both normal and anomalous images ( x X C i Test : y x { 0 , 1 } ).
Multi-class Unsupervised Anomaly Detection. Under the MUAD setting, as illustrated in Figure 1c, a unified model is trained to perform anomaly detection across multiple object classes. The sample set for each experiment X = { X Train , X Test } covers all classes within C . The training dataset X Train = { X C 1 Train , X C 2 Train , , X C N Train } contains the normal images from all classes that are available during training, with class information (i.e., category labels C ) not accessible. The test dataset X Test = { X C 1 Test , X C 2 Test , , X C N Test } includes both normal and anomalous images from test sample sets across all classes. The binary labels ( y x ) and ground truth masks, indicating normal or anomalous images and pixels, are provided, enabling evaluation of the model’s binary classification capabilities at image level (anomaly detection) and pixel level (anomaly localization).

3.2. Revisiting Transformer-Based MUAD

In this section, we review the first MUAD framework, UniAD [5], and outline the motivation for the method proposed in this paper.
UniAD Framework. As shown in Figure 4, UniAD is composed of two main components: a pre-trained, parameter-frozen backbone (denoted as ϕ ) and a transformer-based reconstruction network (denoted as ψ ). The pre-trained backbone serves as a feature extractor, capturing features at multiple spatial scales, which are subsequently aggregated by a fuser F to form a sequence of feature tokens. The feature reconstruction network, which is the core of the framework, follows the standard architecture in vanilla transformer [9] and consists of an encoder ψ E and a decoder ψ D . It effectively mitigates the “identical shortcut” issue by employing a neighbor-masked attention mechanism, introducing feature perturbations, and incorporating learnable queries into the decoder. The anomaly score map of the input image is generated by calculating the distance between the input feature tokens and the reconstructed feature tokens output by ψ . By default, UniAD uses an EfficientNet-b4 [10] as the pre-trained feature extractor, while the feature reconstruction network is made up of 4 encoder layers and 4 decoder layers, with the transformer embedding dimension set to 256.
Motivation for Exploring DualAD. Under the default setup, we noted that UniAD underperforms when using the ResNet [11] series pre-trained backbones [5]. To explore if this issue relates to network capacity, we increased the transformer’s embedding dimension and assessed the model’s detection and localization performance using image-level and pixel-level AUROC, while also tracking performance curves during training. As illustrated in Figure 2, a modest increase in the transformer dimension (from 256 to 512) does improve the performance to a certain degree. However, further increments lead to unstable training performance curves and significant performance degradation. Conversely, reducing the number of transformer layers (from 4 to 2 for both the encoder and decoder) helped restore and even enhance the detection performance.
To delve deeper into the cause of this phenomenon, we followed the method in [5] and additionally trained a decoder to reconstruct images from WideResNet50 features to facilitate the visualization of reconstructed features. As depicted in Figure 3, as the width of the reconstruction network increases, the expansion of parameters seems to make the network overly generalized. While the 1024-dimensional transformer effectively restores structural and semantic anomalies to the normal ones, it struggles with the reconstruction of more intricate and image-specific textural details. This leads the network to mistakenly identify the textures of normal images as anomalies. Conversely, reducing the depth of the reconstruction network allows for better recovery of image textures.
We contend that a key factor in enhancing the performance of feature reconstruction models on diverse pre-trained backbones is to minimize the loss of normal feature information during the reconstruction process, while effectively balancing the decision-making among structural, semantic, and image-specific textural anomalies. From a comprehensive performance perspective, wide and shallow networks appear to be better suited for MUAD tasks. The increased width allows the model to retain pre-trained feature information effectively, while the reduced depth helps prevent overgeneralization, thereby preserving the ability to discern textural anomalies. In contrast, deeper networks excel at understanding structural and semantic features. To harness the benefits of both configurations, we introduce the DualAD framework, which skillfully integrates a Wide–Shallow Network (WSN) with a Narrow–Deep Network (NDN). The WSN enhances the NDN by effectively preserving feature information, while the NDN improves the WSN’s ability to capture complex structural and semantic features, resulting in superior anomaly detection and localization performance.

3.3. Proposed Method

The DualAD framework is proposed for multi-class unsupervised anomaly detection, with Figure 4b and Figure 5 illustrating its two designs: homogeneous and heterogeneous. Overall, our proposed framework comprises two primary components: a Feature Extractor and a Coupled Dual-Branch Network (CDBN). The Feature Extractor aggregates multi-scale features to form a smooth sequence of feature tokens, while the CDBN is composed of a Wide–Shallow Network (WSN) and a Narrow–Deep Network (NDN), which are coupled together to facilitate end-to-end feature reconstruction. Based on the differences between the WSN and NDN architectures, we explore two CDBN designs for DualAD. The homogeneous design (Figure 4b), employs the Transformer for both the WSN and NDN. Conversely, the heterogeneous design (Figure 5) utilizes a Memory-Augmented MLP (MMLP) for the WSN, while retaining the same feature extractor and NDN structure as the homogeneous setup. Detailed descriptions of the framework are elaborated in the subsequent sections.

3.3.1. Feature Extractor

Similar to prior studies [5,40], the Feature Extractor retrieves feature tokens from the multi-scale outputs of the pre-trained backbone. Let ϕ denote the pre-trained backbones, which include L stages { ϕ 1 , ϕ 2 , , ϕ L } , and let S { 1 , 2 , , L } represent the set of selected stage indices. For an input image x R H in × W in × 3 , multi-scale features { f ϕ l = ϕ l ( x ) l S } are extracted from ϕ , where f ϕ l R H l × W l × C l represents the output feature map at stage l of ϕ , with the dimensions H l × W l and C l channels. To achieve spatial alignment of features, each f ϕ l is up-sampled to the resolution H u × W u of the largest feature map among those selected by S , using an interpolation function u. These are then concatenated along the channel dimension to form a C = l S C l channels feature map f u = cat u ( f ϕ l ) l S R H u × W u × C . Subsequently, f u is downsampled to the input resolution of the reconstruction network by local patch aggregation. Specifically, f u is partitioned into ( H u / p ) × ( W u / p ) non-overlapping patches, each of size p × p . The  p 2 embeddings within each patch are aggregated via average pooling to form the feature map f org R H × W × C , where H = H u / p and W = W u / p . Finally, f org is flattened into tokens of length N = H W , which constitute the input h org R N × C for the feature reconstruction network.
The process described above can be summarized in the following pseudocode (Algorithm 1):
Algorithm 1: Feature Extraction Process
Electronics 14 00594 i001

3.3.2. Coupled Dual-Branch Network for Feature Reconstruction

The Dual-Branch Coupled Network (CDBN) is composed of two sub-networks: a Wide–Shallow Network (WSN) and a Narrow–Deep Network (NDN), both consisting of an encoder and a decoder. The WSN has a larger network width to accommodate the high-dimensional properties of the pre-trained features, and with its shallower layers, as analyzed in Section 3.2, it is expected to have better overall anomaly detection and localization capabilities. Simultaneously, we employ a deeper NDN, which is positioned between the encoder and decoder of the WSN and is expected to further extract features from the WSN, enhancing the network’s discriminative capability on structural and semantic anomalies.
As shown in Figure 4 and Figure 5, we denote the encoder of WSN as δ E and the decoder as δ D , while the encoder and decoder of NDN are denoted as ψ E and ψ D , respectively. The original feature tokens h org are first fed into δ E for preliminary feature extraction, resulting in WSN features h wsn = ψ E ( h org ) .
Inspired by the idea of multi-head attention [9] and multi-scale feature fusion [6], we process h wsn in the NDN as follows. First, h wsn is split into N q feature heads Q = { q 1 , q 2 , , q N q } to represent different aspects of h wsn . Then, through an aggregation operation, the aggregated feature h Q is obtained (by default, summation is used, i.e., h Q = i = 1 N q q i ). Next, h Q is fed into the NDN for further processing.
Following UniAD [5], the NDN adopts the standard architecture in vanilla transformer [9] and introduces neighbor masking in the attention calculation to prevent information leakage. Specifically, h Q is first fed into ψ E for further feature extraction, resulting in NDN features h ndn = ψ E ( h Q ) . Subsequently, in each layer of ψ D , h ndn is first fused with a feature head q i Q via a Multi-head Cross Attention (MCA) block (this implies that the number of layers in ψ D equals the number of feature heads K). Then, in the second MCA block, it is fused with the output of the previous decoder layer.
The fused features from each layer of ψ D are sent to a Feed-Forward Network (FFN) block for integration, producing hierarchical features. Finally, we obtain N q hierarchical output features from ψ D , denoted as Z = { z 1 , z 2 , , z N q } , and concatenate them to form the hierarchical aggregated features h Z of the NDN, which are then fed into δ D to obtain the final reconstructed feature tokens h rec .

3.3.3. Memory-Augmented Heterogeneous CDBN

As shown in Figure 4, we explored the design of WSN and NDN with the same architecture—similar to UniAD, both are based on a transformer architecture and coupled together as described in Section 3.3.2, Additionally, to further verify the effectiveness of our CDBN network design, we explored another design scheme where WSN and NDN have different architectures. Specifically, we attempted to implement the encoder and decoder of WSN with a simpler network—a multilayer perceptron (MLP) for both. However, the problem with this simple design is the lack of a mechanism to suppress the “identical shortcut” [5] problem. Therefore, as depicted in Figure 5, we introduced multi-level memory modules [8] to suppress the anomalous information in WSN features.
Each level of the memory modules holds a memory bank M R K × C M , defined as a real-valued matrix containing K memory items with a fixed embedding dimension C M , which is explicitly used to record the prototypical normal patterns of WSN features during training. For ease of calculation, we set C M to be equal to the embedding dimension of the query vectors, which are feature heads q i Q . Memory bank addressing is achieved through soft addressing, where the similarity between the query vector e R C M and each memory item m i R C M ( i { 1 , 2 , , K } ) is used as a weight. Specifically, each weight w i is calculated as follows:
w i = exp e · m i e 2 m i 2 l = 1 K exp e · m l e 2 m l 2 ,
where i = 1 K w i = 1 .
Then, based on the aggregated memory items weighted by w i , the memory representation most related to the query e is retrieved and generated as e ^ :
e ^ = i = 1 L w i m i .
We aim to represent each query e during testing as the normal patterns recorded in the memory bank. However, through the linear combination of memory items, some anomalous features may also be restored well. To alleviate this issue, when calculating e ^ , we ignore those memory items with weights lower than the average value of 1 K , performing sparse addressing such that only a small number of memory items are accessed each time.

3.3.4. Pseudo Anomalies

To mitigate the “identical shortcut” issue, we introduce perturbations to the feature tokens [5], encouraging the model to learn how to reconstruct the input features as normal ones. Specifically, during each iteration of the training phase, a noise token ϵ R N × C is generated for h org , where each entry is sampled from an i.i.d. Gaussian distribution N ( 0 , ( α S ) 2 ) . Here, S represents the instance-wise sample standard deviation of h org at the corresponding channel, and α is a noise scaling parameter. ϵ is then added to h org to obtain the pseudo-anomalous feature tokens.

3.3.5. Training and Inference

The Mean Squared Error (MSE) is utilized to evaluate the reconstruction loss and to compute anomaly scores. To enhance the detection capabilities of features across various hierarchical levels, we employ a weighting mechanism that calculates the average value of channels originating from the same stage. Specifically, let f org l R H × W × C l denote the original feature map slice derived from the l-th stage of ϕ , and let f rec l R H × W × C l denote the corresponding reconstructed feature map slice. For each pair ( f org l , f rec l ) , an anomaly map A l is computed as follows:
l S A l = 1 C l f rec l f org l 2 2 , R H × W .
Training phase. After obtaining the anomaly maps { A l l S } from each stage in S , the reconstruction loss L is calculated by summing over these maps as follows:
L = 1 H W h = 1 H w = 1 W l S A l ( h , w ) .
Inference phase. For pixel-level anomaly localization, we generate an anomaly score map S AL by further processing the anomaly maps across stages S . This map assigns an anomaly score to each pixel of the input image. Specifically, S AL is represented as follows:
S AL = u l S A l R H in × W in ,
where A l denotes the square root of A l , and u is a bilinear interpolation function that upsamples the element-wise product of A l to match the size of the input image.
The image-level anomaly detection result is obtained by computing the maximum value of the average-pooled S AL , providing an overall anomaly score for the image.

3.4. Experimental Setup

In this study, experiments were conducted on two open-source UAD public benchmark datasets, MVTec [12] and VisA [13]. For the training phase, the model is trained on a single NVIDIA GeForce RTX 3080 10GB GPU for 1200 epochs with a batch size of 16. The initial learning rate is set to 1 × 10 4 and is reduced by a factor of 0.1 after 1000 epochs. The AdamW optimizer [55] is used with a weight decay of 1 × 10 4 . For the inference phase, consistent with prior works [5,40,53], anomaly detection and localization results are presented as image-level and pixel-level anomaly scores, with detailed calculation methods provided in Section 3.3.5, rather than as binary classification or segmentation outputs. To assess the model’s performance, we utilized four threshold-independent metrics, covering both image-level and pixel-level evaluation. Each experiment is repeated three times, and intermediate performance results are reported. The specific experimental setups, including the datasets, evaluation metrics, and implementation details, are described below.

3.4.1. Datasets and Evaluation Metrics

MVTec-AD dataset [12] contains 10 object and 5 texture classes of real-world industrial products. Each class contains 60 to 320 color images with resolutions ranging from 700 × 700 to 1024 × 1024 pixels. The training set consists of 3629 anomaly-free images. The test set contains 1725 images, out of which 1258 are anomalous images with different defect types, and pixel-level annotations are provided for the corresponding defective regions. The remaining images in the test set are anomaly-free samples.
VisA dataset [13] comprises 10,821 high-resolution images, including 9621 normal images and 1200 anomalous images. The dataset includes 12 object classes, which are categorized into three different object types: complex structure, multiple instances, and single instance. The anomalous images contain various defects. Each type of defect has 5–20 images, and one image may contain multiple defects. The defects were manually generated to produce realistic anomalies.
Evaluation Metrics. Following prior works [3,7,13], we report the threshold-independent metrics including image-level Area Under the Receiver Operating Curve ( AUROC cls ), Average Precision ( AP cls ), F1-score at optimal threshold ( F 1 max cls ) to measure the performance of image-level anomaly detection and pixel-level localization. Besides, we report the pixel-level Area Under the Receiver Operating Curve ( AUROC sp ) to measure the performance of pixel-level localization).

3.4.2. Baselines and Backbones

We primarily use UniAD [5] as the baseline method for comparison. Additionally, we compare our approach with other recent state-of-the-art methods, including RD4AD [6], SimpleNet [48], ViTAD [40], DiAD [38], and MambaAD [53]. The selection of pre-trained backbone is crucial and is typically based on their demonstrated performance. In this study, all the backbones we use are selected from those employed as feature extractors in the recent state-of-the-art methods we are comparing against. Specifically, UniAD leverages a pre-trained EfficientNet-b4 [10] as its feature extractor, while RD4AD and SimpleNet utilize WideResNet50 [11], DiAD uses ResNet50 [11], MambaAD employs ResNet34 [11], and ViTAD [40] relies on ViT-S [54]. Among these pre-trained backbones, only ViT-S is trained using DINO [56] self-supervision, while the others are supervised models trained on ImageNet [4]. For the ResNet-based backbones (WideResNet50, ResNet34, and ResNet50), feature maps from stages 1 to 3 are selected (i.e., S = 1 , 2 , 3 ), while for EfficientNet-b4 and ViT-S, stages 1 to 4 are used (i.e., S = 1 , 2 , 3 , 4 ). Detailed stage information for the backbones is provided in Table 1. All evaluations are performed under the MUAD setting.

3.4.3. Implementation Details

All input images are resized to 224 × 224 . A pre-trained backbone, as detailed in Section 3.4.2, is utilized as the feature extractor. Feature maps from various stages are selected, aligned, and concatenated, then resized to a 14 × 14 resolution to serve as the input pre-trained features for the reconstruction network. For instance, when using the WideResNet50 pre-trained backbone, features from stages 1 to 3 are selected, aligned, concatenated, and resized to create a 1792-channel feature map, which serves as the reconstruction target for the reconstruction network. In the default setting, the NDN is implemented using a transformer with an embedding dimension of 256, consisting of 4 encoder layers and 4 decoder layers. The input and output dimensions of WSN are set to 1024 by default. In the homogenous CDBN setup, the WSN is implemented using a transformer with 2 encoder layers and 2 decoder layers, while in the heterogeneous CDBN setup, the WSN is an MLP with 1 hidden layer, and the memory item number K is set to 196. For the primary experiments, WideResNet50 is used as the default pre-trained backbone, and the heterogeneous CDBN architecture is adopted, with the noise scale parameter α set to 3.2.

4. Results

4.1. Quantitative Comparisons with SoTAs on MVTec AD and VisA

We compared our method with several state-of-the-art approaches on both the MVTec AD and VisA datasets. The image-level and pixel-level quantitative comparison results for MVTec AD are presented in Table 2 and Table 3, while the results for the VisA dataset are shown in Table 4 and Table 5. It is evident that our proposed framework outperforms the second-best baseline Mamba [53] at image-level performance. However, the pixel-level performance is slightly weaker. We attribute this in part to the fact that, similar to UniAD [5], our end-to-end method downsamples the feature maps to a lower resolution for reconstruction, which may result in a loss of localization precision compared to multi-scale reconstruction-based [6,53] approaches. Additionally, the qualitative results, as shown in Figure 6, visualize the predictions of our model compared to UniAD.

4.2. Ablation Studies

Effectiveness on Different Pre-trained Backbones. To validate the effectiveness of our framework design across different feature extractors, we examined several popular pre-trained backbones used in recent state-of-the-art works, in addition to WideResNet50 used in our main experiments. These include ResNet34 and ResNet50 from the well-known ResNet [11] series, EfficientNet-B4 from the EfficientNet [10] series, and ViT-S from the vision transformer [54] series. Notably, WideResNet50, ResNet34, ResNet50, and EfficientNet-b4 are all supervised-trained on ImageNet1k [4], while ViT-S was selected based on DINO [56] self-supervised training. We tested the performance of both homogeneous (DualAD(Ho)) and heterogeneous (DualAD(He)) CDBN designs and reported the corresponding model complexity. As shown in Table 6, our model’s performance under heterogeneous design is comparable to that under homogeneous design, while being more lightweight. Overall, our framework performs best with WideResNet50.
The Architecture Design of CDBN. We compared the performance of the reconstruction models under our proposed Coupled Dual-Branch Network (CDBN) architecture with that of single-branch architectures (i.e., using only transformer-based UniAD [5] or a single MMLP) across three pre-trained backbones, as shown in Table 7. The results demonstrate that UniAD with a 2-layer encoder–decoder and 1024 embedding dimensions consistently outperforms the UniAD with a 4-layer encoder–decoder and 256 embedding dimensions, which aligns with our analysis in Section 3.2. Additionally, both of our CDBN designs exhibit superior overall performance compared to single-branch architectures. Specifically, to further validate the effectiveness of our CDBN design, we also compared a simple decision fusion (DF) of UniAD models with a 2-layer encoder–decoder (1024 embedding dimensions) and a 4-layer encoder–decoder (256 embedding dimensions). As shown in Table 7, the results reveal that simple decision fusion between the two networks does not yield performance improvements, whereas our coupled dual-branch design more effectively leverages the strengths of both architectures, significantly enhancing overall performance.
Investigating the Impact of the Noise Scale. The scale of noise in feature perturbation controls the distance between the synthesized anomalous features and the reconstructed normal features. Specifically, an excessively large noise scale can make the model overly sensitive to noise, thereby impairing the reconstruction of normal features and leading to erroneous discrimination. On the other hand, a too-small noise scale can result in a blurred decision boundary. Moreover, due to differences among feature extractors, the impact of noise scale may vary. Figure 7 illustrates the influence of noise scale α on model performance when using different pre-trained backbones as feature extractors. From the overall performance curve changes, the selection of an appropriate noise scale appears to be related to the complexity of the model. For instance, implementations based on WideResNet50 and ViT-S require a larger noise scale compared to those based on ResNet34 and EfficientNet-b4 to achieve peak performance.

5. Discussion

In this work, we introduced DualAD, a novel framework for tackling multi-class unsupervised anomaly detection tasks through end-to-end feature reconstruction. We proposed the CDBN, which synergistically integrates a WSN with an NDN to harness their collective strengths, thereby enhancing overall performance. We proposed two CDBN designs: a homogeneous model based entirely on transformers, and a more lightweight heterogeneous design that integrates a transformer with an MMLP. Extensive experiments on the MVTec AD [12] and VisA [13] datasets demonstrated the effectiveness of DualAD, achieving state-of-the-art performance and showcasing its versatility across various pre-trained backbones with differing architectures.
While the results on existing benchmark datasets are promising, we recognize that several important challenges and limitations remain, which should be addressed in future work.
First, despite the excellent performance achieved on MVTec AD [12] and VisA [13], these datasets may not fully capture the diversity and complexity of real-world scenarios. Objects within the same category can exhibit greater variability in appearance than those in these datasets. The current model may not fully generalize to such diversity, and as a result, its applicability to more complex real-world anomaly detection tasks may be limited. If the model were to be applied to more diverse or challenging datasets, such as those with a greater variety of object textures or more noisy data, we hypothesize that performance could degrade, particularly in terms of detecting subtle anomalies. In this case, methods such as domain adaptation or the integration of category labels during training could help the model to better generalize to these real-world complexities, ensuring robustness across a broader range of scenarios.
Second, the scalability of the DualAD framework to larger datasets or real-time processing scenarios remains a significant challenge. The current model may face difficulties when applied to datasets with a substantially larger number of instances or when deployed in real-time environments where computational efficiency is crucial. If the framework were required to operate in such large-scale or real-time scenarios, we anticipate that the computational overhead would become a bottleneck. To mitigate this, future work could focus on optimizing the model’s architecture for faster inference or leveraging more efficient hardware for deployment.
Third, while anomaly detection technologies hold significant potential, their ethical implications must not be overlooked, particularly in sensitive fields such as medical diagnostics and video surveillance. The use of these technologies must comply with stringent privacy and security standards. Therefore, future research should also consider the ethical dimensions of anomaly detection, ensuring that models not only achieve high accuracy but also respect privacy regulations and ethical guidelines.

6. Conclusions

In this study, we introduced the DualAD framework, a promising solution for multi-class unsupervised anomaly detection that enhances performance and flexibility across various backbone architectures. Our extensive experiments highlight its potential to achieve state-of-the-art results on widely-used benchmark datasets, including MVTec AD [12] and VisA [13].
Despite these achievements, several challenges remain. In real-world scenarios, objects within each category often exhibit greater variability in appearance compared to the instances in the MVTec-AD and VisA datasets, which may hinder the model’s ability to generalize effectively. To address this limitation, future research could explore techniques such as domain adaptation or the integration of category labels during training. These strategies could enable the model to better capture the complex distribution patterns of multi-class data, offering a promising direction for further investigation. Moreover, future efforts should focus on improving the scalability and efficiency of the framework, while ensuring its alignment with privacy regulations and ethical standards.

Author Contributions

Conceptualization, S.H.; methodology, S.H. and Y.C.; software, Y.C.; investigation, Y.C. and R.X.; resources, S.H.; writing—original draft preparation, S.H., Y.C., Y.Q., L.W. and W.H.; writing—review and editing, Y.Q., L.W. and W.H.; visualization, Y.C. and R.X.; supervision, Y.Q. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported in part by the National Natural Science Foundation of China under Grants 62371180,in part by the Fundamental Research Funds for the Central Universities of China under Grants JZ2024HGTG0311.

Data Availability Statement

The MVTec AD dataset is accessible under the CC BY-NC-SA 4.0 license and can be downloaded from https://www.mvtec.com/company/research/datasets/mvtec-ad (accessed on 22 May 2024). The VisA dataset is available under the CC BY 4.0 license and can be downloaded from https://amazon-visual-anomaly.s3.us-west-2.amazonaws.com/VisA_20220922.tar (accessed on 22 May 2024). The Python code for DualAD is available at https://github.com/cyhaan/DualAD (accessed on 5 November 2024).

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
ADAnomaly detection
UADUnsupervised anomaly detection
SUADSingle-class unsupervised anomaly detection
MUADMulti-class unsupervised anomaly detection
CDBNCoupled Dual-Branch Network
WSNWide–Shallow Network
NDNNarrow-Deep Network
MMLPMemory-Augmented Multi-Layer Perceptron
MCAMulti-head Cross Attention
FFNFeed-Forward Network
MSEMean Squared Error
AUROCArea Under the Receiver Operating Curve
APAverage Precision
F1maxF1-score at optimal threshold

References

  1. Roth, K.; Pemula, L.; Zepeda, J.; Schölkopf, B.; Brox, T.; Gehler, P. Towards total recall in industrial anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, New Orleans, LA, USA, 18–24 June 2022; pp. 14318–14328. [Google Scholar]
  2. Yu, J.; Zheng, Y.; Wang, X.; Li, W.; Wu, Y.; Zhao, R.; Wu, L. Fastflow: Unsupervised anomaly detection and localization via 2d normalizing flows. arXiv 2021, arXiv:2111.07677. [Google Scholar]
  3. Bergmann, P.; Fauser, M.; Sattlegger, D.; Steger, C. Uninformed students: Student-teacher anomaly detection with discriminative latent embeddings. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA, 13–19 June 2020; pp. 4183–4192. [Google Scholar]
  4. Deng, J.; Dong, W.; Socher, R.; Li, L.J.; Li, K.; Fei-Fei, L. ImageNet: A large-scale hierarchical image database. In Proceedings of the 2009 IEEE Conference on Computer Vision and Pattern Recognition, Miami, FL, USA, 20–25 June 2009; pp. 248–255. [Google Scholar]
  5. You, Z.; Cui, L.; Shen, Y.; Yang, K.; Lu, X.; Zheng, Y.; Le, X. A unified model for multi-class anomaly detection. In Proceedings of the 36th International Conference on Neural Information Processing Systems, New Orleans, LA. USA, 28 November–9 December 2022; pp. 4571–4584. [Google Scholar]
  6. Deng, H.; Li, X. Anomaly detection via reverse distillation from one-class embedding. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, New Orleans, LA, USA, 18–24 June 2022; pp. 9737–9746. [Google Scholar]
  7. Zavrtanik, V.; Kristan, M.; Skočaj, D. Draem-a discriminatively trained reconstruction embedding for surface anomaly detection. In Proceedings of the IEEE/CVF International Conference on Computer Vision, Montreal, QC, Canada, 11–17 October 2021; pp. 8330–8339. [Google Scholar]
  8. Gong, D.; Liu, L.; Le, V.; Saha, B.; Mansour, M.R.; Venkatesh, S.; Hengel, A.v.d. Memorizing normality to detect anomaly: Memory-augmented deep autoencoder for unsupervised anomaly detection. In Proceedings of the IEEE/CVF International Conference On Computer Vision, Seoul, Republic of Korea, 27 October–2 November 2019; pp. 1705–1714. [Google Scholar]
  9. Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, Ł.; Polosukhin, I. Attention is all you need. Adv. Neural Inf. Process. Syst. 2017, 30, 6000–6010. [Google Scholar]
  10. Tan, M.; Le, Q. Efficientnet: Rethinking model scaling for convolutional neural networks. In Proceedings of the International Conference on Machine Learning, Long Beach, CA, USA, 9–15 June 2019; pp. 6105–6114. [Google Scholar]
  11. He, K.; Zhang, X.; Ren, S.; Sun, J. Deep residual learning for image recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA, 27–30 June 2016; pp. 770–778. [Google Scholar]
  12. Bergmann, P.; Fauser, M.; Sattlegger, D.; Steger, C. MVTec AD—A comprehensive real-world dataset for unsupervised anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Long Beach, CA, USA, 15–20 June 2019; pp. 9592–9600. [Google Scholar]
  13. Zou, Y.; Jeong, J.; Pemula, L.; Zhang, D.; Dabeer, O. Spot-the-difference self-supervised pre-training for anomaly detection and segmentation. In Proceedings of the European Conference on Computer Vision, Tel Aviv, Israel, 23–27 October 2022; pp. 392–408. [Google Scholar]
  14. Ruff, L.; Vandermeulen, R.; Goernitz, N.; Deecke, L.; Siddiqui, S.A.; Binder, A.; Müller, E.; Kloft, M. Deep one-class classification. In Proceedings of the International Conference on Machine Learning, Stockholm, Sweden, 10–15 July 2018; pp. 4393–4402. [Google Scholar]
  15. Yi, J.; Yoon, S. Patch svdd: Patch-level svdd for anomaly detection and segmentation. In Proceedings of the Asian Conference on Computer Vision, Kyoto, Japan, 30 November–4 December 2020. [Google Scholar]
  16. Tax, D.M.; Duin, R.P. Support vector data description. Mach. Learn. 2004, 54, 45–66. [Google Scholar] [CrossRef]
  17. Cohen, N.; Hoshen, Y. Sub-image anomaly detection with deep pyramid correspondences. arXiv 2020, arXiv:2005.02357. [Google Scholar]
  18. Hyun, J.; Kim, S.; Jeon, G.; Kim, S.H.; Bae, K.; Kang, B.J. ReConPatch: Contrastive patch representation learning for industrial anomaly detection. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Waikoloa, HI, USA, 3–8 January 2024; pp. 2052–2061. [Google Scholar]
  19. Liu, W.; Chang, H.; Ma, B.; Shan, S.; Chen, X. Diversity-measurable anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 12147–12156. [Google Scholar]
  20. Gu, Z.; Liu, L.; Chen, X.; Yi, R.; Zhang, J.; Wang, Y.; Wang, C.; Shu, A.; Jiang, G.; Ma, L. Remembering normality: Memory-guided knowledge distillation for unsupervised anomaly detection. In Proceedings of the IEEE/CVF International Conference on Computer Vision, Paris, France, 1–6 October 2023; pp. 16401–16409. [Google Scholar]
  21. Zhang, H.; Wu, Z.; Wang, Z.; Chen, Z.; Jiang, Y.G. Prototypical residual networks for anomaly detection and localization. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 16281–16291. [Google Scholar]
  22. Rudolph, M.; Wandt, B.; Rosenhahn, B. Same same but differnet: Semi-supervised defect detection with normalizing flows. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Virtual, 5–9 January 2021; pp. 1907–1916. [Google Scholar]
  23. Gudovskiy, D.; Ishizaka, S.; Kozuka, K. Cflow-ad: Real-time unsupervised anomaly detection with localization via conditional normalizing flows. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Waikoloa, HI, USA, 3–8 January 2022; pp. 98–107. [Google Scholar]
  24. Rudolph, M.; Wehrbein, T.; Rosenhahn, B.; Wandt, B. Fully convolutional cross-scale-flows for image-based defect detection. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Waikoloa, HI, USA, 3–8 January 2022; pp. 1088–1097. [Google Scholar]
  25. Lei, J.; Hu, X.; Wang, Y.; Liu, D. PyramidFlow: High-Resolution Defect Contrastive Localization using Pyramid Normalizing Flow. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 14143–14152. [Google Scholar]
  26. Salehi, M.; Sadjadi, N.; Baselizadeh, S.; Rohban, M.H.; Rabiee, H.R. Multiresolution knowledge distillation for anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Nashville, TN, USA, 19–25 June 2021; pp. 14902–14912. [Google Scholar]
  27. Wang, G.; Han, S.; Ding, E.; Huang, D. Student-teacher feature pyramid matching for anomaly detection. In Proceedings of the The British Machine Vision Conference (BMVC), Online, 22–25 November 2021. [Google Scholar]
  28. Zhang, X.; Li, S.; Li, X.; Huang, P.; Shan, J.; Chen, T. Destseg: Segmentation guided denoising student-teacher for anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 3914–3923. [Google Scholar]
  29. Collin, A.S.; De Vleeschouwer, C. Improved anomaly detection by training an autoencoder with skip connections on images corrupted with stain-shaped noise. In Proceedings of the 2020 25th International Conference on Pattern Recognition (ICPR), Milan, Italy, 10–15 January 2021; pp. 7915–7922. [Google Scholar]
  30. Mishra, P.; Piciarelli, C.; Foresti, G.L. Image anomaly detection by aggregating deep pyramidal representations. In Proceedings of the International Conference on Pattern Recognition, Virtual Event, 10–15 January 2021; pp. 705–718. [Google Scholar]
  31. Ristea, N.C.; Madan, N.; Ionescu, R.T.; Nasrollahi, K.; Khan, F.S.; Moeslund, T.B.; Shah, M. Self-supervised predictive convolutional attentive block for anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, New Orleans, LA, USA, 18–24 June 2022; pp. 13576–13586. [Google Scholar]
  32. Dehaene, D.; Eline, P. Anomaly localization by modeling perceptual features. arXiv 2020, arXiv:2008.05369. [Google Scholar]
  33. Dehaene, D.; Frigo, O.; Combrexelle, S.; Eline, P. Iterative energy-based projection on a normal data manifold for anomaly localization. arXiv 2020, arXiv:2002.03734. [Google Scholar]
  34. Yan, X.; Zhang, H.; Xu, X.; Hu, X.; Heng, P.A. Learning semantic context from normal samples for unsupervised anomaly detection. Proc. AAAI Conf. Artif. Intell. 2021, 35, 3110–3118. [Google Scholar] [CrossRef]
  35. Liang, Y.; Zhang, J.; Zhao, S.; Wu, R.; Liu, Y.; Pan, S. Omni-frequency channel-selection representations for unsupervised anomaly detection. IEEE Trans. Image Process. 2023, 32, 4327–4340. [Google Scholar] [CrossRef] [PubMed]
  36. Wyatt, J.; Leach, A.; Schmon, S.M.; Willcocks, C.G. AnoDDPM: Anomaly detection with denoising diffusion probabilistic models using simplex noise. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, New Orleans, LA, USA, 19–20 June 2022; pp. 650–656. [Google Scholar]
  37. Zhang, H.; Wang, Z.; Wu, Z.; Jiang, Y.G. DiffusionAD: Norm-guided one-step denoising diffusion for anomaly detection. arXiv 2023, arXiv:2303.08730. [Google Scholar]
  38. He, H.; Zhang, J.; Chen, H.; Chen, X.; Li, Z.; Chen, X.; Wang, Y.; Wang, C.; Xie, L. A diffusion-based framework for multi-class anomaly detection. Proc. AAAI Conf. Artif. Intell. 2024, 38, 8472–8480. [Google Scholar] [CrossRef]
  39. Lu, R.; Wu, Y.; Tian, L.; Wang, D.; Chen, B.; Liu, X.; Hu, R. Hierarchical vector quantized transformer for multi-class unsupervised anomaly detection. In Proceedings of the 37th International Conference on Neural Information Processing Systems, New Orleans, LA, USA, 10–16 December 2023; pp. 8487–8500. [Google Scholar]
  40. Zhang, J.; Chen, X.; Wang, Y.; Wang, C.; Liu, Y.; Li, X.; Yang, M.H.; Tao, D. Exploring plain vit reconstruction for multi-class unsupervised anomaly detection. arXiv 2023, arXiv:2312.07495. [Google Scholar]
  41. Gu, A.; Dao, T. Mamba: Linear-time sequence modeling with selective state spaces. arXiv 2023, arXiv:2312.00752. [Google Scholar]
  42. Liu, Z.; Nie, Y.; Long, C.; Zhang, Q.; Li, G. A hybrid video anomaly detection framework via memory-augmented flow reconstruction and flow-guided frame prediction. In Proceedings of the IEEE/CVF International Conference on Computer Vision, Montreal, QC, Canada, 11–17 October 2021; pp. 13588–13597. [Google Scholar]
  43. Hou, J.; Zhang, Y.; Zhong, Q.; Xie, D.; Pu, S.; Zhou, H. Divide-and-assemble: Learning block-wise memory for unsupervised anomaly detection. In Proceedings of the IEEE/CVF International Conference on Computer Vision, Montreal, QC, Canada, 11–17 October 2021; pp. 8791–8800. [Google Scholar]
  44. Li, C.L.; Sohn, K.; Yoon, J.; Pfister, T. Cutpaste: Self-supervised learning for anomaly detection and localization. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Nashville, TN, USA, 19–25 June 2021; pp. 9664–9674. [Google Scholar]
  45. Tien, T.D.; Nguyen, A.T.; Tran, N.H.; Huy, T.D.; Duong, S.; Nguyen, C.D.T.; Truong, S.Q. Revisiting reverse distillation for anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 18–22 June 2023; pp. 24511–24520. [Google Scholar]
  46. Zavrtanik, V.; Kristan, M.; Skočaj, D. DSR—A dual subspace re-projection network for surface anomaly detection. In Proceedings of the European Conference on Computer Vision, Tel Aviv, Israel, 23–27 October 2022; pp. 539–554. [Google Scholar]
  47. Cimpoi, M.; Maji, S.; Kokkinos, I.; Mohamed, S.; Vedaldi, A. Describing textures in the wild. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Columbus, OH, USA, 23–28 June 2014; pp. 3606–3613. [Google Scholar]
  48. Liu, Z.; Zhou, Y.; Xu, Y.; Wang, Z. Simplenet: A simple network for image anomaly detection and localization. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 20402–20411. [Google Scholar]
  49. Van Den Oord, A.; Vinyals, O.; Kavukcuoglu, K. Neural discrete representation learning. Adv. Neural Inf. Process. Syst. 2017, 30, 6309–6318. [Google Scholar]
  50. Jiang, X.; Chen, Y.; Nie, Q.; Liu, J.; Liu, Y.; Wang, C.; Zheng, F. Toward Multi-class Anomaly Detection: Exploring Class-aware Unified Model against Inter-class Interference. arXiv 2024, arXiv:2403.14213. [Google Scholar]
  51. Sitzmann, V.; Martel, J.; Bergman, A.; Lindell, D.; Wetzstein, G. Implicit neural representations with periodic activation functions. Adv. Neural Inf. Process. Syst. 2020, 33, 7462–7473. [Google Scholar]
  52. Zhao, Y. Omnial: A unified cnn framework for unsupervised anomaly localization. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Vancouver, BC, Canada, 17–24 June 2023; pp. 3924–3933. [Google Scholar]
  53. He, H.; Bai, Y.; Zhang, J.; He, Q.; Chen, H.; Gan, Z.; Wang, C.; Li, X.; Tian, G.; Xie, L. Mambaad: Exploring state space models for multi-class unsupervised anomaly detection. arXiv 2024, arXiv:2404.06564. [Google Scholar]
  54. Dosovitskiy, A. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv 2020, arXiv:2010.11929. [Google Scholar]
  55. Loshchilov, I.; Hutter, F. Decoupled Weight Decay Regularization. In Proceedings of the International Conference on Learning Representations, New Orleans, LA, USA, 6–9 May 2019. [Google Scholar]
  56. Caron, M.; Touvron, H.; Misra, I.; Jégou, H.; Mairal, J.; Bojanowski, P.; Joulin, A. Emerging properties in self-supervised vision transformers. In Proceedings of the IEEE/CVF International Conference on Computer Vision, Montreal, BC, Canada, 17–24 June 2021; pp. 9650–9660. [Google Scholar]
Figure 2. Impact of reconstruction model capacity on AD performance.Training performance curves of UniAD with different network configurations on the WideResNet50 backbone are reported. (ad) show settings with a 4-layer encoder and 4-layer decoder. As the transformer dimension increases from (a) 256 to (b) 512, a general improvement in model performance is observed. When the dimension is further increased to (c) 768, pixel-level localization performance slightly declines (with the AUROC peak score decreasing from 97.2 to 96.9). When the dimension is increased to (d) 1024, a significant performance drop is observed, with the performance curve exhibiting severe fluctuations. When (e,f) reduce the number of encoder and decoder layers to 2 in the settings with transformer dimensions of 768 and 1024, the model performance is restored and improved (Figure created by the authors).
Figure 2. Impact of reconstruction model capacity on AD performance.Training performance curves of UniAD with different network configurations on the WideResNet50 backbone are reported. (ad) show settings with a 4-layer encoder and 4-layer decoder. As the transformer dimension increases from (a) 256 to (b) 512, a general improvement in model performance is observed. When the dimension is further increased to (c) 768, pixel-level localization performance slightly declines (with the AUROC peak score decreasing from 97.2 to 96.9). When the dimension is increased to (d) 1024, a significant performance drop is observed, with the performance curve exhibiting severe fluctuations. When (e,f) reduce the number of encoder and decoder layers to 2 in the settings with transformer dimensions of 768 and 1024, the model performance is restored and improved (Figure created by the authors).
Electronics 14 00594 g002
Figure 3. Visualization results of anomaly localization and reconstructed features. (a–f) correspond to the visualization results for the respective models in Figure 2a–f. In the settings of Figure 2c,d, the model struggles to restore the textures of normal objects, such as the patterns on the surface of pills and the grid. Meanwhile, it demonstrates a superior ability to reconstruct structural anomalies of cables and transistors into normal appearances compared to other settings in Figure 2 (Figure created by the authors. Sample images are from the MVTec AD [12] dataset).
Figure 3. Visualization results of anomaly localization and reconstructed features. (a–f) correspond to the visualization results for the respective models in Figure 2a–f. In the settings of Figure 2c,d, the model struggles to restore the textures of normal objects, such as the patterns on the surface of pills and the grid. Meanwhile, it demonstrates a superior ability to reconstruct structural anomalies of cables and transistors into normal appearances compared to other settings in Figure 2 (Figure created by the authors. Sample images are from the MVTec AD [12] dataset).
Electronics 14 00594 g003
Figure 4. (a) UniAD framework: composed of a frozen pre-trained feature extractor and a transformer-based end-to-end feature reconstruction network. (b) Homogeneous DualAD: integrates a wide-shallow and narrow-deep transformer into a unified end-to-end reconstruction network (Figure created by the authors).
Figure 4. (a) UniAD framework: composed of a frozen pre-trained feature extractor and a transformer-based end-to-end feature reconstruction network. (b) Homogeneous DualAD: integrates a wide-shallow and narrow-deep transformer into a unified end-to-end reconstruction network (Figure created by the authors).
Electronics 14 00594 g004
Figure 5. Overview of the proposed heterogeneous DualAD. It comprises two main components: a Feature Extractor that aligns with the homogeneous DualAD, and a Coupled Dual-Branch Network (CDBN), which consists of a Wide–Shallow Network (WSN) and a Narrow–Deep Network (NDN). In contrast to the homogeneous DualAD, the WSN is implemented using a more lightweight Memory-Augmented MLP (MMLP) (Figure created by the authors).
Figure 5. Overview of the proposed heterogeneous DualAD. It comprises two main components: a Feature Extractor that aligns with the homogeneous DualAD, and a Coupled Dual-Branch Network (CDBN), which consists of a Wide–Shallow Network (WSN) and a Narrow–Deep Network (NDN). In contrast to the homogeneous DualAD, the WSN is implemented using a more lightweight Memory-Augmented MLP (MMLP) (Figure created by the authors).
Electronics 14 00594 g005
Figure 6. Qualitative visualized results for anomaly localization (Figure created by the authors. Sample images are from the MVTec AD [12] and VisA [13] datasets).
Figure 6. Qualitative visualized results for anomaly localization (Figure created by the authors. Sample images are from the MVTec AD [12] and VisA [13] datasets).
Electronics 14 00594 g006
Figure 7. Comparison of the four metrics across different backbones under various noise scales (Figure created by the authors).
Figure 7. Comparison of the four metrics across different backbones under various noise scales (Figure created by the authors).
Electronics 14 00594 g007
Table 1. Detailed stage information of the pre-trained backbones involved in this paper.
Table 1. Detailed stage information of the pre-trained backbones involved in this paper.
BackboneStagesDepthsChannelsStrides
Eff-b4[1, 2, 3, 4, 5][1, 4, 5, 12, 10][24, 32, 56, 160, 448][2, 4, 8, 16, 32]
Res34[1, 2, 3, 4][3, 4, 6, 3][64, 128, 256, 512][4, 8, 16, 32]
Res50[1, 2, 3, 4][3, 4, 6, 3][256, 512, 1024, 2048][4, 8, 16, 32]
WRes50[1, 2, 3, 4][3, 4, 6, 3][256, 512, 1024, 2048][4, 8, 16, 32]
ViT-S[1, 2, 3, 4][3, 3, 3, 3][384, 384, 384, 384][16, 16, 16, 16]
Table 2. Comparison with SoTA methods on MVTec-AD dataset for multi-class anomaly detection with AP cls / F 1 max cls metrics.
Table 2. Comparison with SoTA methods on MVTec-AD dataset for multi-class anomaly detection with AP cls / F 1 max cls metrics.
CategoryRD4AD [6]UniAD [5]ViTAD [40]DiAD [38]MambaAD [53]Ours
WRes50 (IN1K)Eff-b4 (IN1K)ViT-S (DINO)Res50 (IN1K)Res34 (IN1K)WRes50 (IN1K)
TextureCarpet99.6/97.299.9/99.499.9/99.499.9/98.399.9/99.499.8/97.7
Grid99.4/96.599.5/97.399.9/99.199.8/97.7100./100.100./99.1
Leather100./100.100./100.100./100.99.7/97.6100./100.100./100.
Tile99.3/96.499.8/98.2100./100.99.9/98.499.3/95.4100./100.
Wood99.8/98.399.6/96.699.6/96.7100./100.99.6/96.699.9/98.3
ObjectBottle99.9/98.4100./100.100./100.96.5/91.8100/100100./100.
Cable89.5/82.595.9/88.099.1/95.798.8/95.299.2/95.799.4/96.7
Capsule96.9/96.997.8/94.499.0/95.597.5/95.598.7/94.599.5/96.9
Hazelnut69.9/86.4100./99.399.9/98.699.7/97.3100./100.100./100.
Metal Nut100./99.599.9/99.599.9/98.496.0/91.6100./99.5100/98.9
Pill99.6/96.898.7/95.799.3/96.498.5/94.599.5/96.299.8/97.9
Screw99.3/95.896.5/89.097.0/93.099.7/97.997.9/94.099.1/95.8
Toothbrush99.9/94.797.4/95.299.6/96.899.9/99.299.3/98.498.5/95.2
Transistor95.2/90.098.0/93.898.3/92.599.6/97.4100./100.100./100.
Zipper99.9/99.299.5/97.199.3/97.199.1/94.499.8/97.599.5/97.5
Mean96.5/95.298.8/96.299.4/97.399.0/96.599.6/97.899.7/98.3
Table 3. Comparison with SoTA methods on MVTec-AD dataset for multi-class anomaly detection with AUROC cls / AUROC sp metrics.
Table 3. Comparison with SoTA methods on MVTec-AD dataset for multi-class anomaly detection with AUROC cls / AUROC sp metrics.
CategoryRD4AD [6]UniAD [5]ViTAD [40]DiAD [38]MambaAD [53]Ours
WRes50 (IN1K)Eff-b4 (IN1K)ViT-S (DINO)Res50 (IN1K)Res34 (IN1K)WRes50 (IN1K)
TextureCarpet98.5/99.099.8/98.599.5/99.099.4/98.699.8/99.299.4/99.0
Grid98.0/96.598.2/63.199.7/98.698.5/96.6100./99.299.9/98.3
Leather100./99.3100./98.8100./99.699.8/98.8100./99.4100./99.1
Tile98.3/95.399.3/91.8100./96.696.8/92.498.2/93.8100./96.1
Wood99.2/95.398.6/93.298.7/96.499.7/93.398.8/94.499.6/95.8
ObjectBottle99.6/97.899.7/98.1100./98.899.7/98.4100./98.8100./98.4
Cable84.1/85.195.2/97.398.5/96.294.8/96.898.8/95.899.0/98.5
Capsule94.1/98.8 86.9/98.595.4/98.389.0/97.194.4/98.497.8/98.8
Hazelnut60.8/97.999.8/98.199.8/99.099.5/98.3100./99.0100./98.5
Metal Nut100./94.899.2/62.799.7/96.499.1/97.399.9/96.799.8/97.6
Pill97.5/97.593.7/95.096.2/98.795.7/95.797.0/97.498.6/98.7
Screw97.7/99.487.5/98.391.3/99.090.7/97.994.7/99.597.1/99.4
Toothbrush97.2/99.094.2/98.498.9/99.199.7/99.098.3/99.096.1/98.6
Transistor94.2/85.999.8/97.9 98.8/93.999.8/95.1100./96.5100./97.0
Zipper99.5/98.595.8/96.897.6/95.995.1/96.299.3/98.498.4/98.6
Mean94.6/96.196.5/96.898.3/97.797.2/96.898.6/97.799.0/98.2
Table 4. Comparison with SoTA methods on VisA dataset for multi-class anomaly detection with AP cls / F 1 max cls metrics.
Table 4. Comparison with SoTA methods on VisA dataset for multi-class anomaly detection with AP cls / F 1 max cls metrics.
CategoryRD4AD [6]UniAD [5]ViTAD [40]DiAD [38]MambaAD [53]Ours
WRes50 (IN1K)Eff-b4 (IN1K)ViT-S(DINO)Res50 (IN1K)Res34 (IN1K)WRes50 (IN1K)
Complex
structure
PCB195.5/91.992.7/87.894.7/91.888.7/80.793.0/91.699.2/96.6
PCB297.8/94.287.7/83.189.9/85.391.4/84.793.7/89.398.3/93.9
PCB396.2/91.078.6/76.191.2/83.987.6/77.694.1/86.796.3/89.3
PCB499.9/99.098.9/94.398.9.96.699.5/97.099.9/98.599.8/98.0
Multiple
instance
Macaroni161.5/76.879.8/69.983.9/76.785.2/78.889.8/81.694.5/88.8
Macaroni284.5/83.871.6/69.974.7/74.957.4/69.578.0/73.880.9/75.8
Capsules90.4/81.355.6/76.987.6/79.869.0/78.595.0/88.890.5/82.4
Candle92.8/86.094.0/86.191.2/83.79.0/87.696.9/90.197.0/91.3
Single
instance
Cashew95.8/90.792.8/91.494.2/86.195.7/89.797.3/91.199.0/94.8
Chewing Gum97.5/92.196.2/95.297.7/91.499.5/95.998.9/94.299.5/97.5
Fryum97.9/91.583.0/85.097.4/90.995.0/87.297.7/90.596.3/88.6
Pipe Fryum98.9/96.594.7/93.999.0/94.798.1/93.799.3/97.099.6/97.5
Mean92.4/89.685.5/84.491.7/86.388.3/85.194.5/89.495.9/91.2
Table 5. Comparison with SoTA methods on VisA dataset for multi-class anomaly detection with AUROC cls / AUROC sp metrics.
Table 5. Comparison with SoTA methods on VisA dataset for multi-class anomaly detection with AUROC cls / AUROC sp metrics.
CategoryRD4AD [6]UniAD [5]ViTAD [40]DiAD [38]MambaAD [53]Ours
WRes50 (IN1K)Eff-b4 (IN1K)ViT-S(DINO)Res50 (IN1K)Res34 (IN1K)WRes50 (IN1K)
Complex
structure
PCB196.2/99.492.8/93.395.8/99.588.1/98.795.4/99.899.3/99.7
PCB297.8/98.087.8/93.990.6/97.991.4/95.294.2/98.998.1/98.8
PCB396.4/97.978.6/97.390.9/98.286.2/96.793.7/99.196.3/99.0
PCB499.9/97.898.8/94.999.1/99.199.6/97.099.9/98.699.7/98.2
Multiple
instance
Macaroni175.9/99.479.9/97.485.8/98.585.7/94.191.6/99.594.7/99.4
Macaroni288.3/99.771.6/95.279.1/98.162.5/93.681.6/99.581.0/98.4
Capsules82.2/99.455.6/88.779.2/98.258.2/97.391.8/99.183.0/99.3
Candle92.3/99.194.1/98.590.4/96.292.8/97.396.8/99.096.6/99.0
Single
instance
Cashew92.0/91.792.8/98.687.8/98.591.5/90.994.5/94.397.9/99.2
Chewing Gum94.9/98.796.3/98.894.9/97.899.1/94.797.7/98.198.9/98.9
Fryum95.3/97.083.0/95.994.3/97.589.8/97.695.2/96.992.0/97.7
Pipe Fryum97.9/99.194.7/98.997.8/99.596.2/99.498.7/99.199.2/99.4
Mean92.4/98.185.5/95.990.5/98.286.8/96.094.3/98.594.7/98.9
Table 6. Ablation studies on pre-trained backbones. The model complexity and performance metrics of the two proposed designs on four different backbones are reported.
Table 6. Ablation studies on pre-trained backbones. The model complexity and performance metrics of the two proposed designs on four different backbones are reported.
MethodParams (M)FLOPs (G)Metrics
AUROC cls AP cls F 1 max cls AUROC sp
DualAD(Ho)WRes50137.324.198.899.697.998.1
Res3489.017.498.399.497.497.9
Res5098.018.298.399.397.697.9
Eff-b486.715.398.899.698.098.0
ViT-S91.619.498.599.498.298.0
DualAD(He)WRes5097.515.599.099.798.398.2
Res3440.97.298.299.497.697.9
Res5054.29.698.399.497.898.1
Eff-b437.54.898.799.698.298.1
ViT-S50.210.598.499.498.198.1
Table 7. Ablation studies on architecture designs. Performance metrics AUROC cls / AP cls / F 1 max cls / AUROC sp are reported.
Table 7. Ablation studies on architecture designs. Performance metrics AUROC cls / AP cls / F 1 max cls / AUROC sp are reported.
MethodBackbones
WRes50Eff-b4ViT-S
UniAD d = 256 , l = 4 91.7/96.9/94.3/96.697.3/99.1/96.8/96.996.8/98.8/97.2/97.6
UniAD d = 1024 , l = 2 97.7/99.2/97.1/97.698.6/99.5/97.8/97.197.9/99.3/97.8/97.8
UniAD DF 96.1/98.7/95.9/97.398.2/99.3/97.5/97.097.7/99.1/97.6/97.7
MMLP97.3/98.8/96.7/97.395.1/97.3/94.8/96.997.2/98.5/96.9/97.6
DualAD(Ho)98.8/99.6/97.9/98.198.8/99.6/98.0/98.098.5/99.4/98.2/98.0
DualAD(He)99.0/99.7/98.3/98.298.7/99.6/98.2/98.198.4/99.4/98.1/98.1
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

He, S.; Chen, Y.; Wang, L.; Huang, W.; Xu, R.; Qian, Y. DualAD: Exploring Coupled Dual-Branch Networks for Multi-Class Unsupervised Anomaly Detection. Electronics 2025, 14, 594. https://doi.org/10.3390/electronics14030594

AMA Style

He S, Chen Y, Wang L, Huang W, Xu R, Qian Y. DualAD: Exploring Coupled Dual-Branch Networks for Multi-Class Unsupervised Anomaly Detection. Electronics. 2025; 14(3):594. https://doi.org/10.3390/electronics14030594

Chicago/Turabian Style

He, Shiwen, Yuehan Chen, Liangpeng Wang, Wei Huang, Rong Xu, and Yurong Qian. 2025. "DualAD: Exploring Coupled Dual-Branch Networks for Multi-Class Unsupervised Anomaly Detection" Electronics 14, no. 3: 594. https://doi.org/10.3390/electronics14030594

APA Style

He, S., Chen, Y., Wang, L., Huang, W., Xu, R., & Qian, Y. (2025). DualAD: Exploring Coupled Dual-Branch Networks for Multi-Class Unsupervised Anomaly Detection. Electronics, 14(3), 594. https://doi.org/10.3390/electronics14030594

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop