Skip to content

Detection

The map of detection

Click an area to open its page, or one of its pages on the right, or the button at the top to go back to the map of the library.

A system that reads numbers all day has three questions to ask of them: what is strange, what has changed, and what to keep out of the model. Detection answers them with three groups of tools.

Anomaly detection. This section is about spotting readings that look strange. Each tool learns from the recent readings what is usual, and gives every new reading a score: the higher the score, the less it looks like the recent past.

Drift detection. While anomaly detection tools spot a single, sudden weird reading, drift detection tools look at the bigger picture. They notice when the baseline level of a system is slowly drifting over time, accumulating tiny, subtle changes that would look perfectly normal if judged on their own.

Protection. When a reading looks wrong, what should you do with it? This section explains the cases (a single glitch, a real change, a slow drift) and which tool handles each.

The three branches

Branch The question Classes
Anomaly detection Each tool learns from the recent readings what is usual, and gives every new reading a score: the higher the score, the less it looks like the recent past. streamDD, MultistreamDD, streamDS, HampelScorer, TukeyScorer, ChauvenetScorer, SigmaClipScorer, HampelFilter, OnlineRobustMahalanobis, LODA, HalfSpaceTrees, OneClassSGD, OnlineIsolationForest, LocalOutlierFactor
Drift detection Anomaly detection flags samples. Drift detection flags a change of the average: something that happens over many samples, each of which looks plausible on its own. ADWIN, BayesianOnlineChangepoint, CUSUMDriftDetector, KSWIN, PageHinkley
Protection Once a sample looks wrong, what do you do with it? Orca, StreamingArbiter, StreamingHealing

The pages of each branch

Anomaly detection

Page What it shows
Streaming per-sample deviation scores, single and multi-channel, plus causal Hampel, Tukey, Chauvenet, sigma clipping and online robust Mahalanobis
Robust filters the four classic detectors on whole series, and the pressure-valve orchestrator
Curvature a bounded proximity-to-reference score in [0, 1)
Online Robust Mahalanobis distance from a robust median under the MCM
LODA rare bins in random 1D projections
Half-Space Trees few reference samples in the region
One-Class SGD (SONAR) distance from a learned kernel boundary
Online Isolation Forest depth to isolate a point
Local Outlier Factor density of the point against its nearest neighbours
Offline algorithms the offline side: an anomaly detector marks the values that do not look like their neighbours

Drift detection

Page What it shows
CUSUM and ARL theory how to detect slow, gradual changes, like a mechanical part wearing out bit by bit: CUSUM accumulates tiny anomalies and triggers an alert when the total deviation confirms a real trend
Offline algorithm the offline side: a change detector reads a series of values and says where its level shifts
Drift detectors how a system notices slow, gradual changes before an outright failure: four tools that pinpoint when a shift has happened, each trading off reaction delay against false alarms

Protection

Page What it shows
Arbiter per-point routing: it decides, reading by reading, whether a glitch should be replaced or a real change kept, and treats it accordingly
Shields a shield cleans a series of numbers or a model
Orca (online) protects a whole model: it cleans the input, runs the model, and checks the answer
Adaptive engine (online) follows a signal that drifts slowly, so that a slow drift is not mistaken for a glitch
Armor (offline) cleans one series of numbers: it finds the readings that are obviously broken and replaces them
Hybrid engine (offline) the part inside Armor that decides whether a value is genuine or broken

Details

  • Detection has an online side, in the pages of the three branches, and an offline side, in the tab Machine learning, whose classes read a whole table at once; the two offline pages are in their branch, with the pages that were in the tab Machine learning.

  • The map is drawn by docs/assets/maps/make_detection_map.py from the menu of mkdocs.yml and from the catalog of the library, so a page added to one of the three branches appears in it when the script is run again.