SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2104.13963 · ICCV · 2021

Semi-Supervised Learning of Visual Features by Non-Parametrically Predicting View Assignments with Support Samples

Mathilde Caron, Ishan Misra, Piotr Bojanowski, Armand Joulin, Michael Rabbat, Nicolas Ballas, Mahmoud Assran

arXiv · PDF · Open in the Atlas

Code that ran

19 of 21 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (4 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 16 have no contract verdict; 3 failures of our instrument; 2 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/2104.13963.json · badge: /api/ran/2104.13963.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
sayakpaul/PAWS-TF community (classifier label)
classifier basis not recorded on the link
12 ran · 2 no recorded run
facebookresearch/msn community
Papers with Code archive
3 ran · 0 no recorded run
facebookresearch/suncet marked official in Papers with Code
Papers with Code archive
2 ran · 0 no recorded run
beresandras/semisupervised-classification-keras community
Papers with Code archive
2 ran · 0 no recorded run
FunctionStatusWhere it lives
AllGather Ran
ran on a synthesized input · constructed an object; no result was computed
facebookresearch/suncet/src/losses.py
code served (permissive licence) · get_code("f68fac75925a8996")
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 an instance of its own class, AllGather: the run constructed the object and did not call it, so no result was computed. 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.autograd

torch.manual_seed(0)

# Since AllGather.forward() expects a single argument 'x' which should be a tensor,
# and the function doesn't initialize dist or check world_size > 1,
# we can construct it in non-distributed mode where it simply returns x.

# The function operates on a tensor x and expects it to be a valid torch tensor
# that can be used with torch.zeros_like() and concatenation operations.

x = torch.randn(2, 4)

ARGS = {
    'x': x
}
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 AllGather — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a AllGather 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
AllReduce Ran
ran on a synthesized input · constructed an object; no result was computed
facebookresearch/msn/src/losses.py
pointer only (licence: NOASSERTION) · get_code("95ac5fe2166b117a")
How it ran

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

PAWS Ran
ran on a synthesized input · constructed an object; no result was computed
beresandras/semisupervised-classification-keras/algorithms.py
code served (permissive licence) · get_code("1bb1dee92e0a093b")
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 an instance of its own class, PAWS: the run constructed the object and did not call it, so no result was computed. 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 tensorflow as tf
from tensorflow import keras
import numpy as np

# Create a minimal augmenter that applies random operations
class MinimalAugmenter(keras.layers.Layer):
    def call(self, images, training=None):
        # Simple pass-through or minimal augmentation
        return images + tf.random.normal(tf.shape(images)) * 0.01

# Create a minimal encoder that outputs feature vectors
class MinimalEncoder(keras.layers.Layer):
    def __init__(self):
        super().__init__()
        self.dense = keras.layers.Dense(8)
    
    def call(self, images, training=None):
        # Flatten and project to feature dimension
        batch_size = tf.shape(images)[0]
        flattened = tf.reshape(images, [batch_size, -1])
        features = self.dense(flattened)
        return features

# Instantiate augmenter and encoder
augmenter = MinimalAugmenter()
encoder = MinimalEncoder()

# Parameters for PAWS
temperature = 0.07
sharpening = 0.25

ARGS = {
    "augmenter": augmenter,
    "encoder": encoder,
    "temperature": temperature,
    "sharpening": sharpening,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type PAWS — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a PAWS 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
SemisupervisedModel Ran
ran on a synthesized input · constructed an object; no result was computed
beresandras/semisupervised-classification-keras/algorithms.py
code served (permissive licence) · get_code("71e80bb6a7133768")
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 an instance of its own class, SemisupervisedModel: the run constructed the object and did not call it, so no result was computed. 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 tensorflow as tf
from tensorflow import keras
import numpy as np

# Create a concrete implementation of SemisupervisedModel
class ConcreteSemisupervisedModel(keras.Model):
    def __init__(self, augmenter, encoder):
        super().__init__()
        self.augmenter = augmenter
        self.encoder = encoder

    def compile(self, optimizer, **kwargs):
        super().compile(**kwargs)
        self.optimizer = optimizer
        self.loss_tracker = keras.metrics.Mean(name='loss')

    @property
    def metrics(self):
        return [self.loss_tracker]

    def semisupervised_loss(self, labels, labeled_features, unlabeled_features_1, unlabeled_features_2):
        # Simple implementation: MSE between unlabeled feature pairs
        return tf.reduce_mean(tf.square(unlabeled_features_1 - unlabeled_features_2))

    def call(self, images, training):
        augmented_images = self.augmenter(images, training=training)
        features = self.encoder(augmented_images, training=training)
        return features

    def train_step(self, data):
        (unlabeled_images, _), (labeled_images, labels) = data
        labeled_images = self.augmenter(labeled_images)
        unlabeled_images_1 = self.augmenter(unlabeled_images)
        unlabeled_images_2 = self.augmenter(unlabeled_images)
        with tf.GradientTape() as tape:
            labeled_features = self.encoder(labeled_images)
            unlabeled_features_1 = self.encoder(unlabeled_images_1)
            unlabeled_features_2 = self.encoder(unlabeled_images_2)
            loss = self.semisupervised_loss(labels, labeled_features, unlabeled_features_1, unlabeled_features_2)
        gradients = tape.gradient(loss, self.trainable_weights)
        self.optimizer.apply_gradients(zip(gradients, self.trainable_weights))
        self.loss_tracker.update_state(loss)
        return {m.name: m.result() for m in self.metrics}

    def test_step(self, data):
        images, labels = data
        labeled_images = self.augmenter(images, training=False)
        unlabeled_images_1 = self.augmenter(images)
        unlabeled_images_2 = self.augmenter(images)
        labeled_features = self.encoder(labeled_images, training=False)
        unlabeled_features_1 = self.encoder(unlabeled_images_1, training=False)
        unlabeled_features_2 = self.encoder(unlabeled_images_2, training=False)
        loss = self.semisupervised_loss(labels, labeled_features, unlabeled_features_1, unlabeled_features_2)
        self.loss_tracker.update_state(loss)
        return {m.name: m.result() for m in self.metrics}


# Create a simple augmenter
class SimpleAugmenter(keras.layers.Layer):
    def __init__(self):
        super().__init__()
    
    def call(self, images, training=None):
        # Simple pass-through augmentation
        return images + tf.random.normal(tf.shape(images), stddev=0.01)


# Create a simple encoder
class SimpleEncoder(keras.layers.Layer):
    def __init__(self):
        super().__init__()
        self.dense = keras.layers.Dense(8)
    
    def call(self, images, training=None):
        return self.dense(images)


# Instantiate components
augmenter = SimpleAugmenter()
encoder = SimpleEncoder()

ARGS = {
    "augmenter": augmenter,
    "encoder": encoder,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type SemisupervisedModel — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a SemisupervisedModel 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
distributed_sinkhorn Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
facebookresearch/msn/src/losses.py
pointer only (licence: NOASSERTION) · get_code("7478f8e64cee8964")
How it ran

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

float_parameter Ran
ran on a synthesized input
sayakpaul/PAWS-TF/utils/multicrop_loader.py
code served (permissive licence) · get_code("0f0390c1cd8dff66")
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 EagerTensor, 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 tensorflow as tf

ARGS = {
    "level": 5,
    "maxval": 255
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, 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
get_paws_loss Ran
ran on a synthesized input
sayakpaul/PAWS-TF/utils/losses.py
code served (permissive licence) · get_code("6a55065d9c679d3c")
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 function. 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 tensorflow as tf

ARGS = {
    "multicrop": 6,
    "tau": 0.1,
    "T": 0.25,
    "me_max": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
init_msn_loss Ran
ran; our contract draft was wrong, not the code
facebookresearch/msn/src/losses.py
pointer only (licence: NOASSERTION) · get_code("8058e8c73e3a9d20")
How it ran

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

init_paws_loss Ran
ran; our contract draft was wrong, not the code
facebookresearch/suncet/src/losses.py
code served (permissive licence) · get_code("e4fcb778fbb424df")
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 function. 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 = {
    "multicrop": 6,
    "tau": 0.1,
    "T": 0.25,
    "me_max": True,
}
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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
layer Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/wide_resnet.py
code served (permissive licence) · get_code("05d7d78714b9de1b")
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 function. 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)

# Define a minimal block that acts as a callable taking (n_input_plane, n_output_plane, stride)
# and returns a callable that processes a tensor
class MinimalBlock(nn.Module):
    def __init__(self, n_input_plane, n_output_plane, stride=(1, 1)):
        super().__init__()
        self.n_input_plane = n_input_plane
        self.n_output_plane = n_output_plane
        self.stride = stride
        # Simple linear layer to transform input to output plane
        self.conv = nn.Linear(n_input_plane, n_output_plane)
    
    def forward(self, x):
        # Expects x to have shape (..., n_input_plane)
        return self.conv(x)

# Define a block factory that returns instances of MinimalBlock
def block_factory(n_input_plane, n_output_plane, stride=(1, 1)):
    return MinimalBlock(n_input_plane, n_output_plane, stride)

# Create test input tensor with batch size 2, feature dimension 4
# This will be passed through the layer function
net_input = torch.randn(2, 4)

# Define arguments for the layer function
ARGS = {
    'block': block_factory,
    'n_input_plane': 4,
    'n_output_plane': 3,
    'count': 3,
    'stride': (1, 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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
learner Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/resnet20.py
code served (permissive licence) · get_code("0756356a6dd842aa")
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 SymbolicTensor. 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 tensorflow as tf
import numpy as np

# Set seed for reproducibility
tf.random.set_seed(0)
np.random.seed(0)

# Create a tiny input tensor
# Shape: (batch_size=2, height=4, width=4, channels=3)
x = tf.random.normal((2, 4, 4, 3))

# Create n_blocks parameter
n_blocks = 1

# Define ARGS dict with all parameters for the learner function
ARGS = {
    'x': x,
    'n_blocks': n_blocks
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type SymbolicTensor — a SymbolicTensor 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
onehot_encode Ran
ran on a synthesized input
sayakpaul/PAWS-TF/utils/labeled_loader.py
code served (permissive licence) · get_code("fe3cc1bc7312b8a0")
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 EagerTensor, ndim 2, dtype family float, shape (2, 10) 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 tensorflow as tf
import numpy as np

# Set seeds for reproducibility
tf.random.set_seed(0)
np.random.seed(0)

# Create valid arguments for onehot_encode
batch_size = 2
num_classes = 10

# labels: (batch_size,) containing class indices in range [0, num_classes)
labels = tf.constant([3, 7], dtype=tf.int32)

# label_smoothing: float parameter
label_smoothing = 0.1

ARGS = {
    "labels": labels,
    "label_smoothing": label_smoothing,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 2, dtype family float, shape (2, 10) — shape (2, 10) 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
projection_head Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/wide_resnet.py
code served (permissive licence) · get_code("cd82cca1cbf4ebbc")
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 EagerTensor, ndim 2, dtype family float, shape (2, 128) 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 tensorflow as tf
import numpy as np

# Set random seeds for reproducibility
tf.random.set_seed(0)
np.random.seed(0)

# Create a small input tensor (batch=2, features=4)
input_tensor = tf.random.normal(shape=(2, 4), dtype=tf.float32)

# Define ARGS with the single parameter
ARGS = {
    'x': input_tensor,
    'hidden_dim': 128
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 2, dtype family float, shape (2, 128) — shape (2, 128) 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
residual_group Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/resnet20.py
code served (permissive licence) · get_code("abadc575eb223999")
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 EagerTensor, ndim 4, dtype family float, shape (2, 2, 2, 32) 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 tensorflow as tf
import numpy as np

# Set seed for reproducibility
tf.random.set_seed(0)
np.random.seed(0)

# Create a small input tensor
# Shape: (batch_size=2, height=4, width=4, channels=3)
x = tf.random.normal((2, 4, 4, 3))

# Define parameters for residual_group
n_filters = 16
n_blocks = 2
strides = (2, 2)
n = 2

ARGS = {
    "x": x,
    "n_filters": n_filters,
    "n_blocks": n_blocks,
    "strides": strides,
    "n": n
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 4, dtype family float, shape (2, 2, 2, 32) — shape (2, 2, 2, 32) 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
sample_level Ran
ran on a synthesized input
sayakpaul/PAWS-TF/utils/multicrop_loader.py
code served (permissive licence) · get_code("08ad311e00fe4f97")
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 EagerTensor, ndim 1, dtype family float, shape (1,) 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 tensorflow as tf

def sample_level(n):
    """
    Uniform sampling with [0.1, n) range.
    """
    return tf.random.uniform(shape=[1], minval=0.1, maxval=n, dtype=tf.float32)

ARGS = {
    "n": 10.0
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 1, dtype family float, shape (1,) — shape (1,) 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
snn Ran
ran on a synthesized input
sayakpaul/PAWS-TF/nn_eval.py
code served (permissive licence) · get_code("3d22afdeab459a13")
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 EagerTensor, ndim 2, dtype family float, shape (2, 5) 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 tensorflow as tf
import numpy as np

# Set seed for reproducibility
np.random.seed(0)
tf.random.set_seed(0)

# Create tiny tensors with distinct dimensions to probe shapes
batch_size_query = 2
batch_size_train = 3
embedding_dim = 4
num_classes = 5

# query: (batch_size, 128) -> using (2, 4) for tiny version
query = tf.constant(np.random.randn(batch_size_query, embedding_dim).astype(np.float32))

# h_train: (batch_size, 128) -> using (3, 4) for tiny version
h_train = tf.constant(np.random.randn(batch_size_train, embedding_dim).astype(np.float32))

# h_labs: (batch_size, 10) -> using (3, 5) for tiny version
# This should be one-hot encoded labels or label probabilities
h_labs = tf.constant(np.random.rand(batch_size_train, num_classes).astype(np.float32))

# temp: temperature hyperparameter
temp = 0.1

ARGS = {
    "query": query,
    "h_train": h_train,
    "h_labs": h_labs,
    "temp": temp,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 2, dtype family float, shape (2, 5) — shape (2, 5) 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
solarize Ran
ran on a synthesized input
sayakpaul/PAWS-TF/utils/multicrop_loader.py
code served (permissive licence) · get_code("879172744bfa9ab1")
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 EagerTensor, ndim 3, dtype family float, shape (4, 3, 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 tensorflow as tf
import numpy as np

# Create a small test image (height=4, width=3, channels=2)
test_image = tf.constant(np.random.randint(0, 256, size=(4, 3, 2), dtype=np.uint8), dtype=tf.float32)

# Map all parameters of the solarize function
ARGS = {
    "image": test_image,
    "level": 6
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 3, dtype family float, shape (4, 3, 2) — shape (4, 3, 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
stem Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/resnet20.py
code served (permissive licence) · get_code("4771975a4479f016")
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 KerasTensor. 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 tensorflow as tf
import numpy as np

# Create a small input tensor for the stem function
# The function expects image-like input with shape (batch, height, width, channels)
# Using batch=2, height=4, width=3, channels=1
batch_size = 2
height = 4
width = 3
channels = 1

inputs = tf.keras.Input(shape=(height, width, channels), batch_size=batch_size)

ARGS = {
    'inputs': inputs
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type KerasTensor — a KerasTensor 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
wide_basic Ran
ran on a synthesized input
sayakpaul/PAWS-TF/models/wide_resnet.py
code served (permissive licence) · get_code("40d8c0a153356fd9")
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 function. 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 tensorflow as tf
from tensorflow.keras import layers, regularizers, Input, Model

# Create a small input tensor to pass through the function
# The function expects a Keras layer/tensor input
batch_size = 2
height = 4
width = 4
input_channels = 3

# Create input layer
input_layer = Input(shape=(height, width, input_channels))

# Define the arguments for wide_basic function
ARGS = {
    'n_input_plane': 3,
    'n_output_plane': 8,
    'stride': (1, 1)
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
dataset_for_class Not yet run
unverified (harvested, no recorded run)
sayakpaul/PAWS-TF/utils/labeled_loader.py
code served (permissive licence) · get_code("9c8af1a1234a70bb")
How it ran

no invocation recorded.

get_support_ds Not yet run
unverified (harvested, no recorded run)
sayakpaul/PAWS-TF/utils/labeled_loader.py
code served (permissive licence) · get_code("c1d2ae4c09280e21")
How it ran

no invocation recorded.

Also present in other papers' code

Of 21 samples lifted from this paper's linked repositories, 21 carry a function identity and 0 do not. Of the 21 distinct functions with an identity, 3 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 3 later) and 18 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
distributed_sinkhorn
brick of this paper's assembly: helper
2 other papers
2 later
2302.10586 (2023-02)
Diffusion Models and Semi-Supervised Learners Benefit Mutually with Few Labels
2407.05862 (2024-07)
Bringing Masked Autoencoders Explicit Contrastive Properties for Point Cloud Self-Supervised Learning
AllReduce
brick of this paper's assembly: helper
1 other paper
1 later · 1 only as an assembly brick
2504.13820 (2025-04)
CheXWorld: Exploring Image World Modeling for Radiograph Representation Learning
init_msn_loss
brick of this paper's assembly: entry
1 other paper
1 later
2407.05862 (2024-07)
Bringing Masked Autoencoders Explicit Contrastive Properties for Point Cloud Self-Supervised Learning

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 proposes a novel method of learning by predicting view assignments with support samples (PAWS). The method trains a model to minimize a consistency loss, which ensures that different views of the same unlabeled instance are assigned similar pseudo-labels. The pseudolabels are generated non-parametrically, by comparing the representations of the image views to those of a set of randomly sampled labeled images. The distance between the view representations and labeled representations is used to provide a weighting over class labels, which we interpret as a soft pseudo-label. By non-parametrically incorporating labeled samples in this way, PAWS extends the distance-metric loss used in self-supervised methods such as BYOL and SwAV to the semi-supervised setting. Despite the simplicity of the approach, PAWS outperforms other semi-supervised methods across architectures, setting a new state-of-the-art for a ResNet-50 on ImageNet trained with either 10% or 1% of the labels, reaching 75.5% and 66.5% top-1 respectively. PAWS requires 4⇥ to 12⇥ less training than the previous best methods.

For agents

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

get_harvested_code_for_paper("2104.13963")
get_code_for_paper("2104.13963")
have("2104.13963")

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

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

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

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

Connect an agent — have() is free.