Abstract
Anomaly detection, which aims to identify anomalies deviating from normal patterns, is challenging due to the limited amount of normal data available. Unlike most existing unified methods that rely on carefully designed image feature extractors and memory banks to capture logical relationships between objects, we introduce a text memory bank to enhance the detection of logical anomalies. Specifically, we propose a Three-Memory framework for Unified structural and logical Anomaly Detection (TMUAD). First, we build a class-level text memory bank for logical anomaly detection by the proposed logic-aware text extractor, which can capture rich logical descriptions of objects from input images. Second, we construct an object-level image memory bank that preserves complete object contours by extracting features from segmented objects. Third, we employ visual encoders to extract patch-level image features for constructing a patch-level memory bank for structural anomaly detection. These three complementary memory banks are used to retrieve and compare normal images that are most similar to the query image, compute anomaly scores at multiple levels, and fuse them into a final anomaly score. By unifying structural and logical anomaly detection through collaborative memory banks, TMUAD achieves state-of-the-art performance across seven publicly available datasets involving industrial and medical domains. The model and code are available at this https URL.
Abstract (translated)
异常检测旨在识别偏离正常模式的异常情况,但由于可用的正常数据量有限,这一任务颇具挑战性。与大多数现有的统一方法不同,这些方法依赖于精心设计的图像特征提取器和内存库来捕捉对象之间的逻辑关系,我们引入了一个文本内存库以增强对逻辑异常的检测能力。具体来说,我们提出了一个用于统一结构化和逻辑异常检测的三内存框架(TMUAD)。 首先,通过提出的具有逻辑感知功能的文本提取器构建了一级类别的文本记忆库,该提取器能够从输入图像中捕获对象的丰富逻辑描述。其次,我们建立了一个基于分割对象提取特征的对象级别图像记忆库,以保留完整的目标轮廓。第三,我们采用视觉编码器来提取补丁级别的图像特征,并构造一个用于结构异常检测的补丁级内存库。 这三个互补的记忆库被用来检索和比较与查询图像最相似的正常图像,在多个层面上计算异常分数并将其融合成最终的异常评分。通过利用协作记忆库统一结构化和逻辑异常检测,TMUAD在涉及工业和医疗领域的七个公开数据集上实现了最先进的性能。模型和代码可在[此处](https://this https URL)获取。
URL
https://arxiv.org/abs/2508.21795