SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2310.07716 · NeurIPS · 2023

PAD: A Dataset and Benchmark for Pose-agnostic Anomaly Detection

Shanghang Zhang, Qiang Zhou, Hao Zhao, Guyue Zhou, Weize Li, Lihan Jiang, Guoliang Wang

arXiv · PDF · Open in the Atlas

Code that ran

10 of 10 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; 1 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 9 failures of our instrument; 0 no recorded run), measured 2026-11-23; 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/2310.07716.json · badge: /api/ran/2310.07716.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
EricLee0224/PAD canonical (classifier label)
classifier basis: census
10 ran · 0 no recorded run
FunctionStatusWhere it lives
build_position_embedding Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
EricLee0224/PAD/models/reconstructions/uniad.py
code served (permissive licence) · get_code("d5b20d47c0675398")
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) and returned PositionEmbeddingSine. 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 torch
import math
from torch import nn

torch.manual_seed(0)

ARGS = {
    'pos_embed_type': 'sine',
    'feature_size': (4, 3),
    'hidden_dim': 128
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type PositionEmbeddingSine — a PositionEmbeddingSine output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a PositionEmbeddingSine 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
conv1x1 Ran
ran; our contract draft was wrong, not the code
EricLee0224/PAD/models/backbones/resnet.py
pointer only (licence: MIT); the stored copy get_code serves, from hlr7999/rlr, is pointer only (licence: NONE) · get_code("fe5ed3e943aa408e")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from hlr7999/rlr, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

conv3x3 Ran
ran; our contract draft was wrong, not the code
EricLee0224/PAD/models/backbones/resnet.py
pointer only (licence: MIT); the stored copy get_code serves, from hlr7999/rlr, is pointer only (licence: NONE) · get_code("2db7a58e9288f8c7")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from hlr7999/rlr, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

extract_feature Ran
ran, honoured the contract we drafted
EricLee0224/PAD/retrieval/retrieval.py
code served (permissive licence) · get_code("0e1afed8adcfa654")
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 Tensor, ndim 2, dtype family float, shape (2, 128) as a later run recorded it. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is not recorded. If your copy returns the same type, ndim and shape 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 torch
import torch.nn as nn
from PIL import Image
import numpy as np

torch.manual_seed(0)

# Create a minimal model that takes input and outputs features
class MinimalModel(nn.Module):
    def __init__(self):
        super(MinimalModel, self).__init__()
        self.fc = nn.Linear(224 * 224 * 3, 128)
    
    def forward(self, x):
        batch_size = x.size(0)
        x = x.view(batch_size, -1)
        x = self.fc(x)
        return x

model = MinimalModel()
model.eval()

# Create small RGB images (numpy arrays) for testing
# Create 2 small RGB images of different sizes to test the function
img1 = np.random.randint(0, 256, (100, 100, 3), dtype=np.uint8)
img2 = np.random.randint(0, 256, (120, 110, 3), dtype=np.uint8)
imgs = [img1, img2]

ARGS = {
    'model': model,
    'imgs': imgs,
    'use_gpu': False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, numpy, torch, torchvision — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 128) — shape (2, 128) as a later run recorded it
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
get_file_list Ran
ran; our contract draft was wrong, not the code
EricLee0224/PAD/retrieval/retrieval.py
code served (permissive licence) · get_code("1a9ae5954fd68227")
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 list, 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 os
import tempfile
import shutil

# Create temporary directories with some test files
temp_dir_1 = tempfile.mkdtemp()
temp_dir_2 = tempfile.mkdtemp()

# Create some dummy files in the directories
for i in range(3):
    with open(os.path.join(temp_dir_1, f"file_{i}.txt"), "w") as f:
        f.write(f"test {i}")
    with open(os.path.join(temp_dir_2, f"data_{i}.txt"), "w") as f:
        f.write(f"data {i}")

ARGS = {
    "file_path_list": [temp_dir_1, temp_dir_2],
    "sort": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 2, dtype family float — a list 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
load_data Ran
ran; our contract draft was wrong, not the code
EricLee0224/PAD/retrieval/retrieval.py
code served (permissive licence) · get_code("4d22a5aa0e4076cf")
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 tempfile
import os
import json
import numpy as np
import imageio
import cv2

# Create a temporary directory structure with test data
temp_dir = tempfile.mkdtemp()

# Create a simple test image (800x800x3)
test_image = np.random.randint(0, 256, (800, 800, 3), dtype=np.uint8)

# Save test image
img_path = os.path.join(temp_dir, 'frame_000.png')
imageio.imwrite(img_path, test_image)

# Create transforms.json
transforms_data = {
    'frames': [
        {
            'file_path': 'frame_000.png',
            'transform_matrix': [
                [1.0, 0.0, 0.0, 0.0],
                [0.0, 1.0, 0.0, 0.0],
                [0.0, 0.0, 1.0, 0.0],
                [0.0, 0.0, 0.0, 1.0]
            ]
        },
        {
            'file_path': 'frame_000.png',
            'transform_matrix': [
                [0.9, 0.1, 0.0, 1.0],
                [-0.1, 0.9, 0.0, 2.0],
                [0.0, 0.0, 1.0, 3.0],
                [0.0, 0.0, 0.0, 1.0]
            ]
        }
    ]
}

transforms_path = os.path.join(temp_dir, 'transforms.json')
with open(transforms_path, 'w') as f:
    json.dump(transforms_data, f)

ARGS = {
    'data_path': temp_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, imageio, numpy — 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
pro_auc_pxl Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
EricLee0224/PAD/util/metric.py
code served (permissive licence) · get_code("22ba49fbcec1ce70")
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 float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape 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

# Create small test data for pro_auc_pxl
# The function expects:
# - gt: ground truth with shape (batch, 1, height, width)
# - score: anomaly scores with shape (batch, height, width)

batch_size = 2
height = 4
width = 3

# Create ground truth with values 0 and 1 (after thresholding)
gt = np.random.rand(batch_size, 1, height, width)
gt[gt > 0.5] = 0.8
gt[gt <= 0.5] = 0.2

# Create anomaly score map with values between 0 and 1
score = np.random.rand(batch_size, height, width)

ARGS = {
    "gt": gt,
    "score": score,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, skimage, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
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
roc_auc_img Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
EricLee0224/PAD/util/metric.py
code served (permissive licence) · get_code("cc3e33dc909f7c67")
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 float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape 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 torch
import numpy as np
from sklearn.metrics import roc_auc_score

torch.manual_seed(0)

# The function roc_auc_img takes two parameters:
# - gt: ground truth labels (passed to roc_auc_score)
# - score: predicted scores (passed to roc_auc_score)
# Both need to be array-like with binary or multi-class labels and scores

# Create ground truth labels (binary classification)
gt = np.array([0, 1, 1, 0, 1, 0])

# Create prediction scores (continuous values between 0 and 1)
score = np.array([0.1, 0.9, 0.8, 0.2, 0.7, 0.3])

ARGS = {
    "gt": gt,
    "score": score
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
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
roc_auc_pxl Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
EricLee0224/PAD/util/metric.py
code served (permissive licence) · get_code("e7389f8fe22ffdb6")
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 float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape 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 torch
import numpy as np

torch.manual_seed(0)

# Create small ground truth array (2D for pixel-level data)
gt = np.random.randint(0, 2, size=(4, 3))

# Create small score array (same shape as gt, with values between 0 and 1)
score = np.random.rand(4, 3)

ARGS = {
    "gt": gt,
    "score": score,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
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
vec2ss_matrix Ran
ran; our contract draft was wrong, not the code
EricLee0224/PAD/util/inerf_helpers.py
code served (permissive licence) · get_code("427a2475db8d1dd1")
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 Tensor, ndim 2, dtype family float, shape (3, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape 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 torch

torch.manual_seed(0)

# The function takes a vector and creates a skew-symmetric matrix from it.
# It expects a vector of at least 3 elements (accesses vector[0], vector[1], vector[2])
vector = torch.tensor([1.0, 2.0, 3.0])

ARGS = {
    "vector": vector
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (3, 3) — shape (3, 3) as a later run recorded it
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

Also present in other papers' code

Of 10 samples lifted from this paper's linked repositories, 10 carry a function identity and 0 do not. Of the 10 distinct functions with an identity, 4 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 2 later) and 6 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.

FunctionAlso present inEarliest-datedOthers named
build_position_embedding 1 other paper
1 dated earlier
2206.03687 (2022-06)
A Unified Model for Multi-class Anomaly Detection
conv1x1 1 other paper
1 later
2403.11561 (2024-03)
Learning Unified Reference Representation for Unsupervised Multi-class Anomaly Detection
conv3x3 1 other paper
1 later
2403.11561 (2024-03)
Learning Unified Reference Representation for Unsupervised Multi-class Anomaly Detection
get_file_list 1 other paper
1 dated earlier
1411.4555 (2014-11)
Show and Tell: A Neural Image Caption Generator

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-23.

Repositories linked to this paper

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

Abstract

Object anomaly detection is an important problem in the field of machine vision and has seen remarkable progress recently. However, two significant challenges hinder its research and application. First, existing datasets lack comprehensive visual information from various pose angles. They usually have an unrealistic assumption that the anomaly-free training dataset is pose-aligned, and the testing samples have the same pose as the training data. However, in practice, anomaly may exist in any regions on a object, the training and query samples may have different poses, calling for the study on pose-agnostic anomaly detection. Second, the absence of a consensus on experimental protocols for pose-agnostic anomaly detection leads to unfair comparisons of different methods, hindering the research on pose-agnostic anomaly detection. To address these issues, we develop Multi-pose Anomaly Detection (MAD) dataset and Pose-agnostic Anomaly Detection (PAD) benchmark, which takes the first step to address the pose-agnostic anomaly detection problem. Specifically, we build MAD using 20 complex-shaped LEGO toys including 4K views with various poses, and high-quality and diverse 3D anomalies in both simulated and real environments. Additionally, we propose a novel method OmniposeAD, trained using MAD, specifically designed for pose-agnostic anomaly detection. Through comprehensive evaluations, we demonstrate the relevance of our dataset and method. Furthermore, we provide an open-source benchmark library, including dataset and baseline methods that cover 8 anomaly detection paradigms, to facilitate future research and application in this domain. Code, data, and models are publicly available at https://github.com/EricLee0224/PAD.

For agents

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

get_harvested_code_for_paper("2310.07716")
get_code_for_paper("2310.07716")
have("2310.07716")

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

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

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

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

Connect an agent — have() is free.