SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1901.03407 · 2019

Deep Learning for Anomaly Detection: A Survey

arXiv · PDF · Open in the Atlas

Code that ran

4 of 4 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 4 have no contract verdict; 0 failures of our instrument; 0 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/1901.03407.json · badge: /api/ran/1901.03407.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
fastforwardlabs/deepad community (classifier label)
classifier basis not recorded on the link
4 ran · 0 no recorded run
FunctionStatusWhere it lives
compute_accuracy Ran
ran on a synthesized input
fastforwardlabs/deepad/utils/eval_utils.py
code served (permissive licence) · get_code("b259a84b8a375955")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import os
import tempfile

# Create a temporary directory for metrics to avoid file I/O issues
temp_dir = tempfile.mkdtemp()
metrics_dir = os.path.join(temp_dir, 'metrics', 'test_model')
os.makedirs(metrics_dir, exist_ok=True)

# Mock the metrics directory path
import matplotlib.pyplot as plt
original_savefig = plt.savefig

def mock_savefig(path, *args, **kwargs):
    # Redirect to temp directory instead of current directory
    temp_path = os.path.join(temp_dir, os.path.basename(path))
    return original_savefig(temp_path, *args, **kwargs)

plt.savefig = mock_savefig

# Generate sample data
np.random.seed(0)

# threshold: a float value for classification threshold
threshold = 0.5

# loss: array of anomaly scores/losses
loss = np.random.rand(20).astype(np.float32)

# y: array of ground truth binary labels
y = np.random.randint(0, 2, 20).astype(int)

# dataset_name: string identifier for the dataset
dataset_name = 'test_dataset'

# show_plot: boolean flag
show_plot = False

# model_name: string identifier for the model
model_name = 'test_model'

ARGS = {
    'threshold': threshold,
    'loss': loss,
    'y': y,
    'dataset_name': dataset_name,
    'show_plot': show_plot,
    'model_name': model_name
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib, numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_scores_and_labels Ran
ran on a synthesized input
fastforwardlabs/deepad/utils/eval_utils.py
code served (permissive licence) · get_code("c206e27d4a8cbe7e")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Construct tiny numpy arrays for inlier and outlier scores
inlier_score = np.array([0.1, 0.2, 0.3])
outlier_score = np.array([0.8, 0.9])

# Map all parameters to their values
ARGS = {
    "outlier_score": outlier_score,
    "inlier_score": inlier_score,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
scale_data Ran
ran on a synthesized input
fastforwardlabs/deepad/utils/data_utils.py
code served (permissive licence) · get_code("faf950b805409a93")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import pandas as pd
import numpy as np
from sklearn.preprocessing import MinMaxScaler

# Create a small sample DataFrame with numeric columns and a target column
np.random.seed(0)
df = pd.DataFrame({
    'feature1': np.random.randn(5),
    'feature2': np.random.randn(5),
    'feature3': np.random.randn(5),
    'target': np.random.randn(5)
})

# Create a scaler instance for testing the else branch
scaler_fitted = MinMaxScaler(feature_range=(0, 1))
scaler_fitted.fit(df.drop(columns='target'))

ARGS = {
    'df': df,
    'scaler': None,
    'drop_col': 'target',
    'dim_size': 2
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, pandas, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
test_threshold Ran
ran on a synthesized input
fastforwardlabs/deepad/utils/eval_utils.py
code served (permissive licence) · get_code("51233759d2ef12ab")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Set random seed for reproducibility
np.random.seed(0)

# Create sample data
# threshold: a float value to use as cutoff
threshold = 0.5

# loss: an array-like of numeric values to compare against threshold
loss = np.array([0.1, 0.3, 0.6, 0.8, 0.2, 0.9])

# y: ground truth labels (binary, 0 or 1)
y = np.array([0, 0, 1, 1, 0, 1])

ARGS = {
    'threshold': threshold,
    'loss': loss,
    'y': y
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block

Also present in other papers' code

Of 4 samples lifted from this paper's linked repositories, 4 carry a function identity and 0 do not. Of the 4 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 4 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Anomaly detection is an important problem that has been well-studied within diverse research areas and application domains. The aim of this survey is two-fold, firstly we present a structured and comprehensive overview of research methods in deep learning-based anomaly detection. Furthermore, we review the adoption of these methods for anomaly across various application domains and assess their effectiveness. We have grouped state-of-the-art research techniques into different categories based on the underlying assumptions and approach adopted. Within each category we outline the basic anomaly detection technique, along with its variants and present key assumptions, to differentiate between normal and anomalous behavior. For each category, we present we also present the advantages and limitations and discuss the computational complexity of the techniques in real application domains. Finally, we outline open issues in research and challenges faced while adopting these techniques.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("1901.03407")
get_code_for_paper("1901.03407")
have("1901.03407")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/1901.03407.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/1901.03407.svg)](https://syntology.ai/paper/1901.03407)

Connect an agent — have() is free.