SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1312.6034 · 2013

Deep Inside Convolutional Networks: Visualising Image Classification Models and Saliency Maps

Andrea Vedaldi, Andrew Zisserman, Karen Simonyan

arXiv · PDF · Open in the Atlas

Code that ran

1 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 0 have no contract verdict; 1 failure of our instrument; 3 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/1312.6034.json · badge: /api/ran/1312.6034.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
KamitaniLab/cnnpref reimplementation (classifier label)
classifier basis: classifier_2025
1 ran · 1 no recorded run
novice03/timm-vis extension (classifier label)
classifier basis: classifier_2025
0 ran · 1 no recorded run
copy not recorded community
not in the paper's declared repositories
0 ran · 1 no recorded run
FunctionStatusWhere it lives
obj_fun Ran
ran; our contract draft was wrong, not the code
KamitaniLab/cnnpref/cnnpref/prefer_img_lbfgs.py
code served (permissive licence) · get_code("fb3b114c01d2c398")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) 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 numpy as np
import os
import PIL.Image
from io import BytesIO

# Create a stand-in class for the Caffe net object
class MockBlob:
    def __init__(self, shape):
        self.data = np.random.randn(*shape).astype(np.float32)
        self.diff = np.zeros(shape, dtype=np.float32)
    
    def fill(self, value):
        self.diff.fill(value)

class MockTransformer:
    def __init__(self):
        self.mean = {'data': np.array([104.0, 117.0, 123.0]).reshape(3, 1, 1)}

class MockNet:
    def __init__(self):
        # Create blobs dictionary with 'data' and a layer blob
        self.blobs = {
            'data': MockBlob((1, 3, 8, 8)),  # batch=1, channels=3, height=8, width=8
            'conv1': MockBlob((1, 5, 6, 6))  # batch=1, channels=5, height=6, width=6
        }
        self.transformer = MockTransformer()
    
    def forward(self, end=None):
        # Mock forward pass - just copy some data
        pass
    
    def backward(self, start=None):
        # Mock backward pass - populate diff in data blob
        self.blobs['data'].diff[0] = np.random.randn(3, 8, 8).astype(np.float32)

# Helper functions that the main function might use
def normalise_img(img):
    """Normalize image to 0-255 range"""
    img = img.copy()
    img -= img.min()
    if img.max() > 0:
        img = img / img.max()
    img = (img * 255).astype(np.uint8)
    if img.ndim == 3:
        img = img.transpose(1, 2, 0)
    return img

def img_deprocess(img, mean):
    """Deprocess image by adding back mean"""
    return img + mean

# Create the arguments
net = MockNet()
img_size = net.blobs['data'].data.shape[-3:]  # (3, 8, 8)
img = np.random.randn(*img_size).astype(np.float32).flatten()

layer = 'conv1'
feature_mask = np.random.randint(0, 2, size=(5, 6, 6)).astype(np.float32)
feature_weight = np.random.randn(5, 6, 6).astype(np.float32)

save_intermediate = False
save_intermediate_every = 10
save_intermediate_path = '/tmp/intermediate'
iter_list = [0]

ARGS = {
    'img': img,
    'net': net,
    'layer': layer,
    'feature_mask': feature_mask,
    'feature_weight': feature_weight,
    'save_intermediate': save_intermediate,
    'save_intermediate_every': save_intermediate_every,
    'save_intermediate_path': save_intermediate_path,
    'iter': iter_list
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
Imports
PIL, 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
fool_model Not yet run
unverified (harvested, no recorded run)
novice03/timm-vis/timm_vis/methods.py
code served (permissive licence) · get_code("4376ea269b06f86b")
How it ran

no invocation recorded.

generate_image Not yet run
unverified (harvested, no recorded run)
this paper's copy was not recorded; identical code first harvested from KamitaniLab/cnnpref
pointer only · get_code("b43d90577686455e")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. 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. No invocation recorded.

generate_image Not yet run
unverified (harvested, no recorded run)
KamitaniLab/cnnpref/cnnpref/prefer_img_lbfgs.py
code served (permissive licence) · get_code("a70f1a3307211511")
How it ran

no invocation recorded.

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, 1 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 1 later) and 3 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
generate_image 3 other papers
3 later
1506.06579 (2015-06)
Understanding Neural Networks Through Deep Visualization
1602.02644 (2016-02)
Generating Images with Perceptual Similarity Metrics based on Deep Networks
1605.09304 (2016-05)
Synthesizing the preferred inputs for neurons in neural networks via deep generator networks

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

This paper addresses the visualisation of image classification models, learnt using deep Convolutional Networks (ConvNets). We consider two visualisation techniques, based on computing the gradient of the class score with respect to the input image. The first one generates an image, which maximises the class score [5], thus visualising the notion of the class, captured by a ConvNet. The second technique computes a class saliency map, specific to a given image and class. We show that such maps can be employed for weakly supervised object segmentation using classification ConvNets. Finally, we establish the connection between the gradient-based ConvNet visualisation methods and deconvolutional networks [13].

For agents

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

get_harvested_code_for_paper("1312.6034")
get_code_for_paper("1312.6034")
have("1312.6034")

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

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

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

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

Connect an agent — have() is free.