Skip to main content

Proportion Localised is a novel metric for visual anomaly detection, intended to be more interpretable than existing metrics. Published in Transactions of Machine Learning Research (TMLR) 2024: VisionAD, a software package of performant anomaly detection algorithms, and Proportion Localised, an interpretable metric.

Project description

Proportion Localised (PL)

Proportion Localised is a novel metric for visual anomaly detection. The metric reports the proportion of anomalies in the dataset sufficiently localized at the best threshold. Note that one image may contain many anomalies.

Getting started - IPython demo

The Github repo (https://github.com/alext1995/proportion-localised) contains demo data and a notebook:

notebooks/pl_demo.ipynb

Clone the repo and run through the notebook to get started!

Pip package

Install the code with:

pip install proportion-localised

PyPI link: https://pypi.org/project/proportion-localised/

Advantages of PL

PL works by splitting each ground truth image into individual anomalies (non-overlapping regions), applying the minimum area rotated bounding box to each anomaly, and measuring the IoU between the prediction and each bounding box. If the IoU > 0.3 (the default IoU limit), then the anomaly is classified as localized. A minimum width and height is enforced for each anomaly, and anomalies with a degree of overlap between each other are merged. This metric provides the researcher or professional with an interpretable method of evaluation for anomaly detection algorithms.

P-AUC and AUPRO are the standard metrics used in the field of anomaly detection; however, these have drawbacks in that they output over a small range of values (0.8-1), are not interpretable, are sensitive to noise from ambiguous pixel-wise labels, and in the case of P-AUC, weigh anomalies in proportion to their size.

Proportion Localised mitigates these drawbacks. The rotated bounding boxes ensure that noise from ambiguous pixel labels is mitigated, and the splitting of the ground truth into discrete anomalies means that each anomaly is weighted equally, regardless of its size. As the output is a proportion, the metric reports between 0 and 1, and the metric has a real physical relation.

Transactions of Machine Learning Research (TMLR) Publication

More details can be found in the Transactions of Machine Learning Research (TMLR) publication: VisionAD, a software package of performant anomaly detection algorithms, and Proportion Localised, an interpretable metric.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

proportion_localised-0.1.3.tar.gz (10.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

proportion_localised-0.1.3-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file proportion_localised-0.1.3.tar.gz.

File metadata

  • Download URL: proportion_localised-0.1.3.tar.gz
  • Upload date:
  • Size: 10.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.9.4

File hashes

Hashes for proportion_localised-0.1.3.tar.gz
Algorithm Hash digest
SHA256 eab96a733e6c9eff2b0bce45d053ba51921baeb7aa4d609db75b8cfdce1b870a
MD5 aa5462d6edac7d326b1880ecc1c6b663
BLAKE2b-256 0047e7d3012c896c64ef0343e2e6b3e4900e35432402731f24e3d74e2ee0cf6c

See more details on using hashes here.

File details

Details for the file proportion_localised-0.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for proportion_localised-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 9c8bbc2f2da2c3f38861cd8428dff7fd12982e3b700c78aac5f64597ce1af4e7
MD5 0408b397f0137934c08359636074b08a
BLAKE2b-256 09cba9ea3a3e83514a41696145dcf342baf85d547e15f00acbe068a1ce0514a7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page