Applied Sciences (Aug 2024)

Back to the Metrics: Exploration of Distance Metrics in Anomaly Detection

  • Yujing Lin,
  • Xiaoqiang Li

DOI
https://doi.org/10.3390/app14167016
Journal volume & issue
Vol. 14, no. 16
p. 7016

Abstract

Read online

With increasing researched focus on industrial anomaly detection, numerous methods have emerged in this domain. Notably, memory bank-based approaches coupled with k distance metrics have demonstrated remarkable performance in anomaly detection (AD) and anomaly segmentation (AS). However, upon examination of the back to the feature (BTF) method applied to the MVTec-3D AD dataset, it was observed that while it exhibited exceptional segmentation performance, its detection performance was lacking. To address this discrepancy, this study improves the implementation of BTF, especially the improvement of the anomaly score metric. It hypothesizes that when calculating the anomaly score for each sample, only the k-nearest neighbors within the same cluster should be considered. For ease of algorithm implementation, this assumption is distilled into the proposition that AD and AS tasks necessitate different k values in k distance metrics. Consequently, the paper introduces the BTM method, which utilizes distinct distance metrics for AD and AS tasks. This innovative approach yields superior AD and AS performance (I-AUROC 93.0%, AURPO 96.9%, P-AUROC 99.5%), representing a substantial enhancement over the BTF method (I-AUROC 5.7% ↑, AURPO 0.5% ↑, P-AUROC 0.2% ↑).

Keywords