SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper · ICCV · 2025

LaCoOT: Layer Collapse through Optimal Transport

Enzo Tartaglione, Fabio Pizzati, Victor Quétu, Zhu Liao, Nour Hezbri

Open in the Atlas

Code that ran

6 of 6 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; 6 failures of our instrument; 0 no recorded run), measured 2026-11-24; 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/Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper.json · badge: /api/ran/Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper.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
VGCQ/LaCoOT canonical (classifier label)
classifier basis: census
6 ran · 0 no recorded run
FunctionStatusWhere it lives
conv1x1 Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/models/ResNet.py
code served (permissive licence) · get_code("158bf4c3a5f11f04")
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 Conv2d. 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
from torch import nn

torch.manual_seed(0)

ARGS = {
    "in_planes": 3,
    "out_planes": 64,
    "stride": 1,
}
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 Conv2d — a Conv2d output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Conv2d 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
conv3x3 Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/models/ResNet.py
code served (permissive licence) · get_code("29df79c9fdb0cee8")
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 Conv2d. 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 = {
    "in_planes": 3,
    "out_planes": 64,
    "stride": 1,
    "groups": 1,
    "dilation": 1,
}
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 Conv2d — a Conv2d output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Conv2d 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
get_cifar10 Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/dataloaders/cifar10.py
code served (permissive licence) · get_code("2da4f07a3351a751")
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 torch
import torchvision
from torchvision import transforms
from unittest.mock import Mock, MagicMock
import tempfile
import os

torch.manual_seed(0)

# Create a temporary directory for the dataset root
temp_dir = tempfile.mkdtemp()

# Create a mock args object with all required attributes
class Args:
    def __init__(self):
        self.root = temp_dir
        self.batch_size = 2
        self.workers = 0
        self.distributed = False

args = Args()

# Create minimal mock CIFAR10 datasets to avoid actual download
class MockCIFAR10Dataset:
    def __init__(self, root, train=True, transform=None, download=False):
        self.root = root
        self.train = train
        self.transform = transform
        self.download = download
        self.classes = ['airplane', 'automobile', 'bird', 'cat', 'deer', 'dog', 'frog', 'horse', 'ship', 'truck']
        self.data = torch.randint(0, 256, (10, 3, 32, 32), dtype=torch.uint8)
        self.targets = [i % 10 for i in range(10)]
    
    def __len__(self):
        return len(self.targets)
    
    def __getitem__(self, idx):
        x = self.data[idx]
        if self.transform:
            from PIL import Image
            x = Image.fromarray(x.permute(1, 2, 0).numpy())
            x = self.transform(x)
        else:
            x = x.float() / 255.0
        y = self.targets[idx]
        return x, y

# Monkey-patch torchvision.datasets.CIFAR10
original_cifar10 = torchvision.datasets.CIFAR10
torchvision.datasets.CIFAR10 = MockCIFAR10Dataset

ARGS = {
    'args': args,
    'size_train_set': 0.9,
    'get_train_sampler': False,
    'transform_train': True
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, torch, torchvision — 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
get_tinyimagenet200 Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/dataloaders/tinyimagenet200.py
code served (permissive licence) · get_code("36d56f94b2d76a9b")
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 torch
import torchvision
from torchvision import transforms
import os
import tempfile
from pathlib import Path

torch.manual_seed(0)

# Create a temporary directory structure for tiny imagenet
temp_dir = tempfile.mkdtemp()
train_dir = os.path.join(temp_dir, 'train')
val_dir = os.path.join(temp_dir, 'val')
test_dir = os.path.join(temp_dir, 'test')

os.makedirs(train_dir, exist_ok=True)
os.makedirs(val_dir, exist_ok=True)
os.makedirs(test_dir, exist_ok=True)

# Create dummy class directories and images
for split_dir in [train_dir, val_dir, test_dir]:
    for class_id in range(2):
        class_dir = os.path.join(split_dir, f'class_{class_id}')
        os.makedirs(class_dir, exist_ok=True)
        
        # Create a small dummy image file
        from PIL import Image
        import numpy as np
        
        img_array = np.random.randint(0, 255, (64, 64, 3), dtype=np.uint8)
        img = Image.fromarray(img_array)
        img.save(os.path.join(class_dir, 'dummy_0.jpg'))
        img.save(os.path.join(class_dir, 'dummy_1.jpg'))

class ArgsConfig:
    def __init__(self, root, batch_size=2, workers=0, distributed=False):
        self.root = root
        self.batch_size = batch_size
        self.workers = workers
        self.distributed = distributed

ARGS = {
    'args': ArgsConfig(root=temp_dir, batch_size=2, workers=0, distributed=False),
    'get_train_sampler': False,
    'transform_train': True
}
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 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
mobilenet_v2 Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/models/Mobilenetv2.py
code served (permissive licence) · get_code("2954c0acc6ee0e01")
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 MobileNetV2. 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 = {
    'pretrained': False,
    'progress': True,
    'device': 'cpu',
}
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 MobileNetV2 — a MobileNetV2 output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a MobileNetV2 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
split_dataset Ran
ran; our contract draft was wrong, not the code
VGCQ/LaCoOT/dataloaders/utils.py
code served (permissive licence) · get_code("bf8a250ffd6dbadb")
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 numpy as np
import torch
from torch import Generator
from torch.utils.data import random_split, Dataset

torch.manual_seed(0)

class SimpleDataset(Dataset):
    def __init__(self, size=10):
        self.size = size
        self.data = torch.randn(size, 4)
        self.labels = torch.randint(0, 2, (size,))
    
    def __len__(self):
        return self.size
    
    def __getitem__(self, idx):
        return self.data[idx], self.labels[idx]

dataset = SimpleDataset(size=10)

ARGS = {
    'dataset': dataset,
    'percentage': 0.3,
    'random_seed': 42,
    'ds_name': '',
    'train_percentage': 1.0
}
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 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

Also present in other papers' code

Of 6 samples lifted from this paper's linked repositories, 6 carry a function identity and 0 do not. Of the 6 distinct functions with an identity, 3 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 2 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
conv1x1 431 other papers
401 dated earlier, 13 later, 16 same year, order not determinable, 1 undated · 38 only as an assembly brick
1409.1556 (2014-09)
Very Deep Convolutional Networks for Large-Scale Image Recognition
1506.01186 (2015-06)
Cyclical Learning Rates for Training Neural Networks
1507.05717 (2015-07)
An End-to-End Trainable Neural Network for Image-based Sequence Recognition and Its Application to Scene Text Recognition
and 428 more not named here
conv3x3 312 other papers
290 dated earlier, 9 later, 12 same year, order not determinable, 1 undated · 31 only as an assembly brick
1409.1556 (2014-09)
Very Deep Convolutional Networks for Large-Scale Image Recognition
1507.05717 (2015-07)
An End-to-End Trainable Neural Network for Image-based Sequence Recognition and Its Application to Scene Text Recognition
1512.03385 (2015-12)
Deep Residual Learning for Image Recognition
and 309 more not named here
mobilenet_v2 4 other papers
3 dated earlier, 1 same year, order not determinable
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
2403.06014 (2024-03)
Hard-label based Small Query Black-box Adversarial Attack
2405.18902 (2024-05)
A Causal Framework for Evaluating Deferring Systems
and 1 more not named here

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

Repositories linked to this paper

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

Abstract

Although deep neural networks are well-known for their outstanding performance in tackling complex tasks, their hunger for computational resources remains a significant hurdle, posing energy-consumption issues and restricting their deployment on resource-constrained devices, preventing their widespread adoption. In this paper, we present an optimal transport-based method to reduce the depth of over-parametrized deep neural networks, alleviating their computational burden. More specifically, we propose a new regularization strategy based on the Max-Sliced Wasserstein distance to minimize the distance between the intermediate feature distributions in the neural network. We show that minimizing this distance enables the complete removal of intermediate layers in the network, achieving better performance/depth trade-off compared to existing techniques. We assess the effectiveness of our method on traditional image classification setups and extend it to generative image models. Our code is available at https://github.com/VGCQ/LaCoOT.

For agents

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

get_harvested_code_for_paper("Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper")
get_code_for_paper("Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper")
have("Quetu_LaCoOT_Layer_Collapse_through_Optimal_Transport_ICCV_2025_paper")

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

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

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

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

Connect an agent — have() is free.