SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2007.02269 · 2020

Rethinking Bottleneck Structure for Efficient Mobile Network Design

arXiv · PDF · Open in the Atlas

Code that ran

9 of 9 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 6 have no contract verdict; 3 failures of our instrument; 0 no recorded run), measured 2026-11-21; 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/2007.02269.json · badge: /api/ran/2007.02269.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
Andrew-Qibin/ssdlite-pytorch canonical (classifier label)
classifier basis: census
6 ran · 0 no recorded run
zhoudaquan/rethinking_bottleneck_design canonical (classifier label)
classifier basis: classifier_2025
3 ran · 0 no recorded run
FunctionStatusWhere it lives
add_extras Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/modeling/backbone/vgg.py
code served (permissive licence) · get_code("4033f0f966d86b4c")
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 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
import torch.nn as nn

torch.manual_seed(0)

# Construct valid arguments for add_extras function
# The function takes:
# - cfg: a config (iterable of values, some integers and 'S' strings)
# - i: input channels (integer)
# - size: optional size parameter (default 300)

# Build a minimal cfg that exercises the function logic
# cfg should contain integers and 'S' markers
cfg = [64, 'S', 128, 'S', 256, 512]

# i is the initial input channels
i = 3

# size can be 300 or 512 to test different branches
size = 300

ARGS = {
    'cfg': cfg,
    'i': i,
    'size': size
}
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 list, ndim 1, 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
add_vgg Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/modeling/backbone/vgg.py
code served (permissive licence) · get_code("b3ab5e255848ed6e")
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 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
import torch.nn as nn

torch.manual_seed(0)

# The function expects:
# - cfg: a list/iterable containing integers (channel counts) and strings ('M' or 'C' for pooling)
# - batch_norm: a boolean flag

cfg = [64, 'M', 128, 'M', 256, 256, 'C', 512, 512, 'M', 512, 512]

batch_norm = False

ARGS = {
    'cfg': cfg,
    'batch_norm': batch_norm,
}
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 list, ndim 1, 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
compute_on_dataset Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/engine/inference.py
code served (permissive licence) · get_code("75cc7cb3f9efa8d2")
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 torch
import torch.nn as nn
import torch.utils.data

torch.manual_seed(0)

# Define a minimal model that accepts images and returns a list of outputs
class MinimalModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 3)
    
    def forward(self, x):
        # x shape: (batch_size, 4)
        # Return a list of tensors, one per image in batch
        batch_size = x.shape[0]
        outputs = [self.linear(x[i:i+1]) for i in range(batch_size)]
        return outputs

# Create model
model = MinimalModel()

# Create a minimal data loader
# Each batch should be (images, targets, image_ids)
class MinimalDataset(torch.utils.data.Dataset):
    def __init__(self, num_samples=4):
        self.num_samples = num_samples
    
    def __len__(self):
        return self.num_samples
    
    def __getitem__(self, idx):
        # images: tensor of shape (4,)
        # targets: dummy tensor
        # image_ids: string identifier
        images = torch.randn(4)
        targets = torch.tensor(0)
        image_ids = f"img_{idx}"
        return images, targets, image_ids

# Create dataset and data loader
dataset = MinimalDataset(num_samples=4)
data_loader = torch.utils.data.DataLoader(
    dataset,
    batch_size=2,
    collate_fn=lambda batch: (
        torch.stack([item[0] for item in batch]),
        torch.stack([item[1] for item in batch]),
        [item[2] for item in batch]
    )
)

# Set device to CPU
device = torch.device('cpu')

# Define ARGS
ARGS = {
    'model': model,
    'data_loader': data_loader,
    'device': device
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, tqdm — 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
conv_1x1_bn Ran
ran; our contract draft was wrong, not the code
zhoudaquan/rethinking_bottleneck_design/mobile_deployment/pytorch/InvBlock/models/imagenet/i2rnet.py
pointer only (licence: NOASSERTION) · get_code("a0131fb70c267a9e")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, zhoudaquan/rethinking_bottleneck_design (NOASSERTION). 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.

conv_1x1_bn Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/modeling/backbone/mobilenext.py
code served (permissive licence) · get_code("778b1206838f15e8")
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 Sequential. 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 torch.nn as nn

torch.manual_seed(0)

# The function conv_1x1_bn takes two parameters: inp (input channels) and oup (output channels)
# These are integers representing the number of input and output channels for the Conv2d layer

inp = 3
oup = 4

ARGS = {
    "inp": inp,
    "oup": oup
}
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 Sequential — a Sequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Sequential output the recorded ndim 1 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
conv_3x3_bn Ran
ran; our contract draft was wrong, not the code
zhoudaquan/rethinking_bottleneck_design/mobile_deployment/pytorch/InvBlock/models/imagenet/i2rnet.py
pointer only (licence: NOASSERTION) · get_code("408e747e0425a594")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, zhoudaquan/rethinking_bottleneck_design (NOASSERTION). 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.

conv_3x3_bn Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/modeling/backbone/mobilenext.py
code served (permissive licence) · get_code("141234d4962cebd2")
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 Sequential. 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 torch.nn as nn

torch.manual_seed(0)

ARGS = {
    'inp': 3,
    'oup': 16,
    'stride': 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 Sequential — a Sequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Sequential output the recorded ndim 1 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
group_conv_1x1_bn Ran
ran; our contract draft was wrong, not the code
zhoudaquan/rethinking_bottleneck_design/mobile_deployment/pytorch/InvBlock/models/imagenet/i2rnet.py
pointer only (licence: NOASSERTION) · get_code("8334eff690ba0f90")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, zhoudaquan/rethinking_bottleneck_design (NOASSERTION). 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.

sg_block_extra Ran
ran on a synthesized input
Andrew-Qibin/ssdlite-pytorch/ssd/modeling/backbone/mobilenext.py
code served (permissive licence) · get_code("e8df26eea356566d")
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 Sequential. 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 torch.nn as nn

torch.manual_seed(0)

ARGS = {
    'inp': 3,
    'oup': 16,
    'stride': 1,
    'expand_ratio': 6,
    'last': False
}
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 Sequential — a Sequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Sequential output the recorded ndim 1 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 9 samples lifted from this paper's linked repositories, 9 carry a function identity and 0 do not. Of the 7 distinct functions with an identity, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 0 the same month, 2 later) and 2 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
conv_1x1_bn 31 other papers
12 dated earlier, 18 later, 1 same year, order not determinable · 2 only as an assembly brick
1703.07402 (2017-03)
Simple Online and Realtime Tracking with a Deep Association Metric
1801.04381 (2018-01)
MobileNetV2: Inverted Residuals and Linear Bottlenecks
1811.08383 (2018-11)
TSM: Temporal Shift Module for Efficient Video Understanding
and 28 more not named here
conv_3x3_bn 12 other papers
3 dated earlier, 8 later, 1 same year, order not determinable
1801.04381 (2018-01)
MobileNetV2: Inverted Residuals and Linear Bottlenecks
1904.07399 (2019-04)
Adaptive Wing Loss for Robust Face Alignment via Heatmap Regression
1911.08114 (2019-11)
Neural Network Pruning with Residual-Connections and Limited-Data
and 9 more not named here
add_extras 1 other paper
1 dated earlier
1512.02325 (2015-12)
SSD: Single Shot MultiBox Detector
add_vgg 1 other paper
1 dated earlier
1512.02325 (2015-12)
SSD: Single Shot MultiBox Detector
compute_on_dataset 1 other paper
1 dated earlier
1512.02325 (2015-12)
SSD: Single Shot MultiBox Detector

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

Repositories linked to this paper

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

Abstract

The inverted residual block is dominating architecture design for mobile networks recently. It changes the classic residual bottleneck by introducing two design rules: learning inverted residuals and using linear bottlenecks. In this paper, we rethink the necessity of such design changes and find it may bring risks of information loss and gradient confusion. We thus propose to flip the structure and present a novel bottleneck design, called the sandglass block, that performs identity mapping and spatial transformation at higher dimensions and thus alleviates information loss and gradient confusion effectively. Extensive experiments demonstrate that, different from the common belief, such bottleneck structure is more beneficial than the inverted ones for mobile networks. In ImageNet classification, by simply replacing the inverted residual block with our sandglass block without increasing parameters and computation, the classification accuracy can be improved by more than 1.7% over MobileNetV2. On Pascal VOC 2007 test set, we observe that there is also 0.9% mAP improvement in object detection. We further verify the effectiveness of the sandglass block by adding it into the search space of neural architecture search method DARTS. With 25% parameter reduction, the classification accuracy is improved by 0.13% over previous DARTS models. Code can be found at: https://github.com/zhoudaquan/rethinking_bottleneck_design.

For agents

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

get_harvested_code_for_paper("2007.02269")
get_code_for_paper("2007.02269")
have("2007.02269")

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

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

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

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

Connect an agent — have() is free.