SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2004.13166 · 2020

A Disentangling Invertible Interpretation Network for Explaining Latent Representations

arXiv · PDF · Open in the Atlas

Code that ran

12 of 14 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 11 have no contract verdict; 0 failures of our instrument; 2 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/2004.13166.json · badge: /api/ran/2004.13166.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
CompVis/iin community (classifier label)
classifier basis not recorded on the link
9 ran · 1 no recorded run
KongBOy/analyze_16_code_iin community (classifier label)
classifier basis not recorded on the link
3 ran · 1 no recorded run
FunctionStatusWhere it lives
adopt_weight Ran
ran, honoured the contract we drafted
CompVis/iin/iin/losses/ae.py
pointer only (licence: MIT); the stored copy get_code serves, from joanrod/ocr-vqgan, is pointer only (licence: NONE) · get_code("7439a9d4c6be04b0")
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 joanrod/ocr-vqgan, 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.

get_learning_rate Ran
ran on a synthesized input
CompVis/iin/iin/iterators/base.py
code served (permissive licence) · get_code("a6900d411978f53b")
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

torch.manual_seed(0)

# Test case 1: config with 'learning_rate' key
config1 = {
    'learning_rate': 0.001
}

# Test case 2: config with 'base_learning_rate' and 'batch_size' keys
config2 = {
    'base_learning_rate': 0.0001,
    'batch_size': 32
}

ARGS = {
    'config': config1
}
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 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
isflow Ran
ran on a synthesized input
KongBOy/analyze_16_code_iin/try_edexplore.py
code served (permissive licence) · get_code("089f1a241531ba82")
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 bool, 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 a valid flow array (3D numpy array with last dimension = 2)
flow_array = np.random.randn(4, 5, 2).astype(np.float32)

ARGS = {
    "obj": flow_array
}
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 bool, 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
isimage Ran
ran on a synthesized input
KongBOy/analyze_16_code_iin/try_edexplore.py
code served (permissive licence) · get_code("6050fa71db03b49d")
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 bool, 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

# Test case 1: Valid RGB image (3-channel)
valid_rgb_image = np.random.randint(0, 256, size=(32, 64, 3), dtype=np.uint8)

# Test case 2: Valid grayscale image (1-channel)
valid_gray_image = np.random.randint(0, 256, size=(32, 64, 1), dtype=np.uint8)

# Test case 3: Valid RGBA image (4-channel)
valid_rgba_image = np.random.randint(0, 256, size=(32, 64, 4), dtype=np.uint8)

# Test case 4: Invalid - 2D array (not an image)
invalid_2d = np.random.randint(0, 256, size=(32, 64), dtype=np.uint8)

# Test case 5: Invalid - wrong number of channels
invalid_channels = np.random.randint(0, 256, size=(32, 64, 5), dtype=np.uint8)

# Test case 6: Invalid - not an ndarray
invalid_not_ndarray = [[1, 2, 3], [4, 5, 6]]

ARGS = {
    "obj": valid_rgb_image
}
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 bool, 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
l1 Ran
ran on a synthesized input
CompVis/iin/iin/losses/ae.py
code served (permissive licence) · get_code("7ef28876c796d72c")
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)

input_tensor = torch.randn(2, 4)
target_tensor = torch.randn(2, 4)

ARGS = {
    "input": input_tensor,
    "target": target_tensor,
}
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
l2 Ran
ran on a synthesized input
CompVis/iin/iin/losses/ae.py
code served (permissive licence) · get_code("4d2ab2a1446f3762")
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 small tensors for input and target
input_tensor = torch.randn(2, 4)
target_tensor = torch.randn(2, 4)

ARGS = {
    "input": input_tensor,
    "target": target_tensor,
}
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
loss_callback Ran
ran on a synthesized input
CompVis/iin/iin/iterators/iin.py
code served (permissive licence) · get_code("5b8377efee227f73")
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 numpy as np

torch.manual_seed(0)

# Construct root - appears to be unused in the function, so a simple object
class Root:
    pass

root = Root()

# Construct data_in - appears to be unused in the function, so a simple object
class DataIn:
    pass

data_in = DataIn()

# Construct data_out - needs a 'labels' dict with a 'loss' key containing array-like data
class DataOut:
    def __init__(self):
        self.labels = {
            'loss': np.array([0.5, 0.7, 0.3, 0.9])
        }

data_out = DataOut()

# Construct config - appears to be unused in the function, so a simple dict
config = {}

ARGS = {
    'root': root,
    'data_in': data_in,
    'data_out': data_out,
    'config': config
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — 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
loss_callback Ran
ran on a synthesized input
KongBOy/analyze_16_code_iin/iin/iterators/iin.py
code served (permissive licence) · get_code("fdda1426d1bb0886")
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

torch.manual_seed(0)

# Build minimal root object (appears to be unused in function body)
root = None

# Build data_in - small tensor batch
data_in = torch.randn(2, 4)

# Build data_out - small tensor batch
data_out = torch.randn(2, 3)

# Build config dict
config = {
    'learning_rate': 0.001,
    'batch_size': 2,
}

ARGS = {
    'root': root,
    'data_in': data_in,
    'data_out': data_out,
    'config': config,
}
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 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
nll Ran
ran on a synthesized input
CompVis/iin/iin/losses/iin.py
code served (permissive licence) · get_code("2c181328877e9fc7")
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 1, dtype family float, shape (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
import torch.nn as nn

torch.manual_seed(0)

# The function nll expects a sample tensor
# It computes: 0.5 * sum of squares along dimensions [1, 2, 3]
# This means the input should be at least 4D (indices 0, 1, 2, 3 exist)
# Dimension 0 is batch, dimensions 1, 2, 3 are spatial/feature dims

sample = torch.randn(2, 4, 3, 5)  # batch=2, dim1=4, dim2=3, dim3=5

ARGS = {
    "sample": sample
}
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 1, dtype family float, shape (2,) — shape (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
reconstruction_callback Ran
ran on a synthesized input
CompVis/iin/iin/iterators/ae.py
code served (permissive licence) · get_code("799ba3b3a1846793")
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 numpy as np
from collections import namedtuple

torch.manual_seed(0)

# Create a simple stand-in for root parameter
root = None

# Create a stand-in for data_in parameter
data_in = None

# Create a stand-in for data_out with labels attribute containing rec_loss and kl_loss
DataOut = namedtuple('DataOut', ['labels'])
data_out = DataOut(
    labels={
        'rec_loss': np.array([0.5, 0.7, 0.6]),
        'kl_loss': np.array([0.2, 0.3, 0.25])
    }
)

# Create a simple config dict
config = {
    'model_type': 'vae',
    'latent_dim': 4,
    'batch_size': 2
}

ARGS = {
    'root': root,
    'data_in': data_in,
    'data_out': data_out,
    'config': config
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — 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
tonp Ran
ran on a synthesized input
CompVis/iin/iin/iterators/base.py
code served (permissive licence) · get_code("3d7adb2f95674903")
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 4, dtype family float, shape (2, 4, 5, 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
import numpy as np

torch.manual_seed(0)

# Test case 1: A 4D tensor (image-like) with guess_image=True
# Shape: (batch=2, channels=3, height=4, width=5)
tensor_4d = torch.randn(2, 3, 4, 5)

# Test case 2: A non-4D tensor with guess_image=True
tensor_2d = torch.randn(2, 10)

# Test case 3: A numpy array (no .detach() method)
numpy_array = np.array([1, 2, 3, 4])

ARGS = {
    "x": tensor_4d,
    "guess_image": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 4, dtype family float, shape (2, 4, 5, 3) — shape (2, 4, 5, 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
totorch Ran
ran on a synthesized input
CompVis/iin/iin/iterators/base.py
code served (permissive licence) · get_code("f884ce744d1572d7")
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 4, dtype family float, shape (2, 5, 3, 4) 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 numpy as np

torch.manual_seed(0)

# Create a small numpy array with shape (2, 3, 4, 5) to test the 4D transpose logic
x_4d = np.random.randn(2, 3, 4, 5).astype(np.float32)

# Create a small numpy array with shape (2, 3) to test non-4D case
x_2d = np.random.randn(2, 3).astype(np.float32)

# Create a float64 array to test dtype conversion
x_float64 = np.random.randn(2, 3).astype(np.float64)

ARGS = {
    "x": x_4d,
    "guess_image": True,
    "device": torch.device('cpu')
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (2, 5, 3, 4) — shape (2, 5, 3, 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
clf_callback Not yet run
unverified (harvested, no recorded run)
CompVis/iin/iin/iterators/clf.py
code served (permissive licence) · get_code("d34031e4ccffb523")
How it ran

no invocation recorded.

istext Not yet run
unverified (harvested, no recorded run)
KongBOy/analyze_16_code_iin/try_edexplore.py
code served (permissive licence) · get_code("2256a23076322784")
How it ran

no invocation recorded.

Also present in other papers' code

Of 14 samples lifted from this paper's linked repositories, 14 carry a function identity and 0 do not. Of the 14 distinct functions with an identity, 2 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 2 later) and 12 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
adopt_weight 9 other papers
9 later
2012.09841 (2020-12)
Taming Transformers for High-Resolution Image Synthesis
2112.00384 (2021-12)
Exploration into Translation-Equivariant Image Quantization
2211.13221 (2022-11)
Latent Video Diffusion Models for High-Fidelity Long Video Generation
and 6 more not named here
tonp 1 other paper
1 later
2008.01777 (2020-08)
Making Sense of CNNs: Interpreting Deep Representations & Their Invariances with INNs

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

Neural networks have greatly boosted performance in computer vision by learning powerful representations of input data. The drawback of end-to-end training for maximal overall performance are black-box models whose hidden representations are lacking interpretability: Since distributed coding is optimal for latent layers to improve their robustness, attributing meaning to parts of a hidden feature vector or to individual neurons is hindered. We formulate interpretation as a translation of hidden representations onto semantic concepts that are comprehensible to the user. The mapping between both domains has to be bijective so that semantic modifications in the target domain correctly alter the original representation. The proposed invertible interpretation network can be transparently applied on top of existing architectures with no need to modify or retrain them. Consequently, we translate an original representation to an equivalent yet interpretable one and backwards without affecting the expressiveness and performance of the original. The invertible interpretation network disentangles the hidden representation into separate, semantically meaningful concepts. Moreover, we present an efficient approach to define semantic concepts by only sketching two images and also an unsupervised strategy. Experimental evaluation demonstrates the wide applicability to interpretation of existing classification and image generation networks as well as to semantically guided image manipulation.

For agents

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

get_harvested_code_for_paper("2004.13166")
get_code_for_paper("2004.13166")
have("2004.13166")

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

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

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

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

Connect an agent — have() is free.