Crane: Context-Guided Prompt Learning and Attention Refinement for Zero-Shot Anomaly Detections

Bibliographic Details
Title: Crane: Context-Guided Prompt Learning and Attention Refinement for Zero-Shot Anomaly Detections
Authors: Salehi, Alireza, Salehi, Mohammadreza, Hosseini, Reshad, Snoek, Cees G. M., Yamada, Makoto, Sabokrou, Mohammad
Publication Year: 2025
Collection: Computer Science
Subject Terms: Computer Science - Computer Vision and Pattern Recognition
More Details: Anomaly Detection (AD) involves identifying deviations from normal data distributions and is critical in fields such as medical diagnostics and industrial defect detection. Traditional AD methods typically require the availability of normal training samples; however, this assumption is not always feasible, as collecting such data can be impractical. Additionally, these methods often struggle to generalize across different domains. Recent advancements, such as AnomalyCLIP and AdaCLIP, utilize the zero-shot generalization capabilities of CLIP but still face a performance gap between image-level and pixel-level anomaly detection. To address this gap, we propose a novel approach that conditions the prompts of the text encoder based on image context extracted from the vision encoder. Also, to capture fine-grained variations more effectively, we have modified the CLIP vision encoder and altered the extraction of dense features. These changes ensure that the features retain richer spatial and structural information for both normal and anomalous prompts. Our method achieves state-of-the-art performance, improving performance by 2% to 29% across different metrics on 14 datasets. This demonstrates its effectiveness in both image-level and pixel-level anomaly detection.
Document Type: Working Paper
Access URL: http://arxiv.org/abs/2504.11055
Accession Number: edsarx.2504.11055
Database: arXiv
More Details
Description not available.