SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1811.07130 · 2018

Batch DropBlock Network for Person Re-identification and Beyond

arXiv · PDF · Open in the Atlas

Code that ran

10 of 12 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 7 have no contract verdict; 2 failures of our instrument; 2 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/1811.07130.json · badge: /api/ran/1811.07130.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
daizuozhuo/batch-dropblock-network community (classifier label)
classifier basis not recorded on the link
9 ran · 1 no recorded run
zjjszj/ps_dm_reid reimplementation (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
zjjszj/batch-feature-erasing community (classifier label)
classifier basis not recorded on the link
0 ran · 1 no recorded run
FunctionStatusWhere it lives
GaussDistribution Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/utils/DistWeightDevianceLoss.py
code served (permissive licence) · get_code("a8ca488a78fe3000")
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 1, 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 torch

torch.manual_seed(0)

# Create a small tensor for the data parameter
data = torch.randn(2, 4)

ARGS = {
    "data": data
}
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 tuple, ndim 1, 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
k_reciprocal_neigh Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/trainers/re_ranking.py
code served (permissive licence) · get_code("a610e67edff490e6")
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 ndarray, ndim 1, dtype family int, shape (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 numpy as np

# Create a small initial_rank matrix
# The function indexes into this with [i, :k1+1] and [forward_k_neigh_index, :k1+1]
# So we need enough rows and columns
initial_rank = np.array([
    [0, 1, 2, 3, 4],
    [1, 0, 3, 2, 4],
    [2, 3, 0, 1, 4],
    [3, 2, 1, 0, 4],
    [4, 0, 1, 2, 3]
], dtype=np.int64)

# i is an index into the first dimension of initial_rank
i = 0

# k1 is used to slice the rank matrix up to k1+1
k1 = 2

ARGS = {
    "initial_rank": initial_rank,
    "i": i,
    "k1": k1
}
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 ndarray, ndim 1, dtype family int, shape (3,) — shape (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
normalize Ran
ran; our contract draft was wrong, not the code
daizuozhuo/batch-dropblock-network/utils/loss.py
code served (permissive licence) · get_code("e3b2a83f52101f2d")
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, 4) 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)

# Create a small tensor with batch size 2 and feature dimension 4
x = torch.randn(2, 4)

ARGS = {
    "x": x,
    "axis": -1
}
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 (2, 4) — shape (2, 4) 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
pdist Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/utils/loss.py
code served (permissive licence) · get_code("58f365883f647099")
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, 2) 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)

# Construct a small tensor A with shape (2, 4)
# The function computes pairwise distances between rows of A
A = torch.randn(2, 4)

# Define ARGS dict with all parameters
ARGS = {
    'A': A,
    'squared': False,
    'eps': 0.0001
}
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 (2, 2) — shape (2, 2) 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
re_ranking Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/trainers/re_ranking.py
code served (permissive licence) · get_code("0d0c0c2ee0cbcc00")
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 ndarray, ndim 2, dtype family float, shape (2, 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 numpy as np

np.random.seed(0)

# Create small distance matrices
# q_g_dist: query-gallery distances (query_num x gallery_num)
query_num = 2
gallery_num = 3

q_g_dist = np.random.rand(query_num, gallery_num).astype(np.float32)

# q_q_dist: query-query distances (query_num x query_num)
q_q_dist = np.random.rand(query_num, query_num).astype(np.float32)

# g_g_dist: gallery-gallery distances (gallery_num x gallery_num)
g_g_dist = np.random.rand(gallery_num, gallery_num).astype(np.float32)

ARGS = {
    'q_g_dist': q_g_dist,
    'q_q_dist': q_q_dist,
    'g_g_dist': g_g_dist,
    'k1': 20,
    'k2': 6,
    'lambda_value': 0.3
}
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 ndarray, ndim 2, dtype family float, shape (2, 3) — shape (2, 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
re_ranking_new Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/trainers/re_ranking.py
code served (permissive licence) · get_code("e366124173574e1d")
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 ndarray, ndim 2, dtype family float, shape (2, 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 numpy as np

# Create small distance matrices for testing
# q_g_dist: query-to-gallery distances (num_queries x num_gallery)
# q_q_dist: query-to-query distances (num_queries x num_queries)
# g_g_dist: gallery-to-gallery distances (num_gallery x num_gallery)

num_queries = 2
num_gallery = 3

# Create small random distance matrices (similarity scores, typically in [0,1])
np.random.seed(0)
q_g_dist = np.random.rand(num_queries, num_gallery).astype(np.float32)
q_q_dist = np.random.rand(num_queries, num_queries).astype(np.float32)
g_g_dist = np.random.rand(num_gallery, num_gallery).astype(np.float32)

# Make symmetric
q_q_dist = (q_q_dist + q_q_dist.T) / 2
g_g_dist = (g_g_dist + g_g_dist.T) / 2

ARGS = {
    'q_g_dist': q_g_dist,
    'q_q_dist': q_q_dist,
    'g_g_dist': g_g_dist,
    'k1': 2,
    'k2': 2,
    'lambda_value': 0.3
}
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 ndarray, ndim 2, dtype family float, shape (2, 3) — shape (2, 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
read_image Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/datasets/data_loader.py
code served (permissive licence) · get_code("80bda819706e052f")
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 Image. 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
from PIL import Image

# Create a temporary image file for testing
temp_dir = tempfile.mkdtemp()
temp_image_path = os.path.join(temp_dir, "test_image.jpg")

# Create a simple RGB image and save it
test_image = Image.new('RGB', (100, 100), color='red')
test_image.save(temp_image_path)

ARGS = {
    'img_path': temp_image_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Image — a Image output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Image output the recorded ndim 3 and dtype family int 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
similarity Ran
ran; our contract draft was wrong, not the code
daizuozhuo/batch-dropblock-network/utils/DistWeightDevianceLoss.py
pointer only (licence: MIT); the stored copy get_code serves, from biqing-qi/interactive-continual-learning-fast-and-slow-thinking, is pointer only (licence: NONE) · get_code("4b11b485195acac8")
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 biqing-qi/interactive-continual-learning-fast-and-slow-thinking, 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.

test Ran
ran, honoured the contract we drafted
zjjszj/ps_dm_reid/main_reid.py
code served (permissive licence) · get_code("99bbeaa12c80f194")
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 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 torch.nn as nn

torch.manual_seed(0)

# Build a minimal model that satisfies the function's usage
class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.fc = nn.Linear(4, 3)  # 4 input features, 3 output classes
    
    def forward(self, x):
        return self.fc(x)

model = SimpleModel()

# Build a minimal queryloader
# The function expects tuples of (data, target, _) where:
# - data is a tensor that can be passed to model
# - target is a tensor of class labels
# - _ is ignored (third element)
class SimpleDataset:
    def __init__(self):
        self.data = [
            (torch.randn(2, 4), torch.tensor([0, 1]), None),
            (torch.randn(2, 4), torch.tensor([2, 0]), None),
        ]
    
    def __iter__(self):
        return iter(self.data)
    
    def __len__(self):
        return len(self.data)

queryloader = SimpleDataset()
queryloader.dataset = queryloader

ARGS = {
    "model": model,
    "queryloader": queryloader,
}
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 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
topk_mask Ran
ran on a synthesized input
daizuozhuo/batch-dropblock-network/utils/loss.py
code served (permissive licence) · get_code("2d401581cceae6a4")
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, 4) 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)

# Create a small input tensor (batch=2, features=4)
input_tensor = torch.randn(2, 4)

# Define ARGS mapping all parameters
ARGS = {
    "input": input_tensor,
    "dim": 1,
    "K": 2,
}
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 (2, 4) — shape (2, 4) 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
init_dataset Not yet run
unverified (harvested, no recorded run)
daizuozhuo/batch-dropblock-network/datasets/data_manager.py
code served (permissive licence) · get_code("6c89823f3dcd9176")
How it ran

no invocation recorded.

init_dataset Not yet run
unverified (harvested, no recorded run)
zjjszj/batch-feature-erasing/datasets/data_manager.py
code served (permissive licence) · get_code("076552aac0a5dd3d")
How it ran

no invocation recorded.

Also present in other papers' code

Of 12 samples lifted from this paper's linked repositories, 12 carry a function identity and 0 do not. Of the 11 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, 4 later) and 7 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
normalize 29 other papers
2 dated earlier, 27 later
1609.01775 (2016-09)
Performance Measures and a Data Set for Multi-Target, Multi-Camera Tracking
1804.01438 (2018-04)
Learning Discriminative Features with Multiple Granularities for Person Re-Identification
1902.09212 (2019-02)
Deep High-Resolution Representation Learning for Human Pose Estimation
and 26 more not named here
k_reciprocal_neigh 5 other papers
2 dated earlier, 3 later
1804.01438 (2018-04)
Learning Discriminative Features with Multiple Granularities for Person Re-Identification
1805.09501 (2018-05)
AutoAugment: Learning Augmentation Policies from Data
1812.03282 (2018-12)
Spatial-Temporal Person Re-identification
and 2 more not named here
read_image 2 other papers
2 later
1905.00953 (2019-05)
Omni-Scale Feature Learning for Person Re-Identification
similarity 1 other paper
1 later
2403.02628 (2024-03)
Interactive Continual Learning: Fast and Slow Thinking

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

Since the person re-identification task often suffers from the problem of pose changes and occlusions, some attentive local features are often suppressed when training CNNs. In this paper, we propose the Batch DropBlock (BDB) Network which is a two branch network composed of a conventional ResNet-50 as the global branch and a feature dropping branch. The global branch encodes the global salient representations. Meanwhile, the feature dropping branch consists of an attentive feature learning module called Batch DropBlock, which randomly drops the same region of all input feature maps in a batch to reinforce the attentive feature learning of local regions. The network then concatenates features from both branches and provides a more comprehensive and spatially distributed feature representation. Albeit simple, our method achieves state-of-the-art on person re-identification and it is also applicable to general metric learning tasks. For instance, we achieve 76.4% Rank-1 accuracy on the CUHK03-Detect dataset and 83.0% Recall-1 score on the Stanford Online Products dataset, outperforming the existing works by a large margin (more than 6%).

For agents

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

get_harvested_code_for_paper("1811.07130")
get_code_for_paper("1811.07130")
have("1811.07130")

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

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

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

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

Connect an agent — have() is free.