SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2406.19300 · 2024

scTree: Discovering Cellular Hierarchies in the Presence of Batch Effects in scRNA-seq Data

arXiv · PDF · Open in the Atlas

Code that ran

6 of 10 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 0 have no contract verdict; 5 failures of our instrument; 4 no recorded run), measured 2026-11-23; 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/2406.19300.json · badge: /api/ran/2406.19300.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
mvandenhi/sctree-public canonical (classifier label)
classifier basis: census
6 ran · 4 no recorded run
FunctionStatusWhere it lives
actvn Ran
ran; our contract draft was wrong, not the code
mvandenhi/sctree-public/src/sctree/models/networks.py
code served (permissive licence) · get_code("aa82271694aa26fb")
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
import torch.nn.functional as F

torch.manual_seed(0)

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 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
cluster_acc Ran
ran; our contract draft was wrong, not the code
mvandenhi/sctree-public/src/sctree/utils/utils.py
code served (permissive licence) · get_code("8b187044b46776ff")
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 float64, ndim 0, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

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

# Create small sample data for clustering evaluation
# y_true: ground truth labels
y_true = np.array([0, 0, 1, 1, 2, 2], dtype=np.int64)

# y_pred: predicted cluster labels
# Using a permuted/noisy version of true labels to simulate clustering output
y_pred = np.array([0, 0, 2, 2, 1, 1], dtype=np.int64)

# return_index parameter
return_index = False

ARGS = {
    "y_true": y_true,
    "y_pred": y_pred,
    "return_index": return_index,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float64, ndim 0, dtype family float — no output shape is stated: observe_signature.py recorded float ndim 0, which disagrees with the fixture run
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_posterior Ran
ran, honoured the contract we drafted
mvandenhi/sctree-public/src/sctree/utils/model_utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from JoGo175/diffuse-treevae, is pointer only (licence: NONE) · get_code("1490267abbaf552e")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from JoGo175/diffuse-treevae, 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.

construct_tree Ran
ran; our contract draft was wrong, not the code
mvandenhi/sctree-public/src/sctree/utils/model_utils.py
code served (permissive licence) · get_code("a3068f593f9b81dd")
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 Node. 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)

# Create simple nn.Module instances for transformations
class SimpleTransformation(nn.Module):
    def __init__(self, in_dim=4, out_dim=4):
        super().__init__()
        self.linear = nn.Linear(in_dim, out_dim)
    
    def forward(self, x):
        return self.linear(x)

# Create simple router modules
class SimpleRouter(nn.Module):
    def __init__(self, in_dim=4):
        super().__init__()
        self.linear = nn.Linear(in_dim, 2)
    
    def forward(self, x):
        return self.linear(x)

# Create simple dense modules
class SimpleDense(nn.Module):
    def __init__(self, in_dim=4, out_dim=3):
        super().__init__()
        self.linear = nn.Linear(in_dim, out_dim)
    
    def forward(self, x):
        return self.linear(x)

# Create simple decoder modules
class SimpleDecoder(nn.Module):
    def __init__(self, in_dim=4, out_dim=2):
        super().__init__()
        self.linear = nn.Linear(in_dim, out_dim)
    
    def forward(self, x):
        return self.linear(x)

# Construct the argument lists
num_nodes = 3  # For a small tree with 3 nodes

transformations = [SimpleTransformation(4, 4) for _ in range(num_nodes)]
routers = [SimpleRouter(4) for _ in range(num_nodes)]
routers_q = [SimpleDense(4, 3) for _ in range(num_nodes)]
denses = [SimpleDense(4, 3) for _ in range(num_nodes)]

# Only the leaf nodes (last ones) should have decoders
decoders = [None, None, SimpleDecoder(4, 2)]

ARGS = {
    'transformations': transformations,
    'routers': routers,
    'routers_q': routers_q,
    'denses': denses,
    'decoders': decoders,
}
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 Node — a Node output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Node 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
merge_yaml_args Ran
ran; our contract draft was wrong, not the code
mvandenhi/sctree-public/src/sctree/utils/utils.py
code served (permissive licence) · get_code("8bf333e25cc959aa")
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 argparse import Namespace

# Create a configs dictionary with nested structure
configs = {
    'model': {
        'learning_rate': 0.001,
        'batch_size': 32,
        'hidden_dim': 128
    },
    'data': {
        'num_epochs': 10,
        'shuffle': True
    },
    'training': {
        'optimizer': 'adam',
        'loss_fn': 'mse'
    }
}

# Create args as a Namespace object with some overlapping and new keys
args = Namespace(
    learning_rate=0.002,  # This should update configs['model']['learning_rate']
    batch_size=64,        # This should update configs['model']['batch_size']
    num_epochs=20,        # This should update configs['data']['num_epochs']
    new_param='value1',   # This is not in configs, should go to 'parser'
    another_new_param=42  # This is not in configs, should go to 'parser'
)

ARGS = {
    'configs': configs,
    'args': args
}
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
prepare_config Ran
ran; our contract draft was wrong, not the code
mvandenhi/sctree-public/src/sctree/utils/utils.py
code served (permissive licence) · get_code("d670f4e0166ca03c")
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 os
import tempfile
from pathlib import Path
import yaml
from argparse import Namespace

# Create a temporary directory structure with a config file
temp_dir = tempfile.TemporaryDirectory()
project_dir = Path(temp_dir.name)
configs_dir = project_dir / 'configs'
configs_dir.mkdir(parents=True, exist_ok=True)

# Create a sample YAML config file
config_data = {
    'globals': {
        'seed': 42,
        'batch_size': 32,
        'learning_rate': 0.001
    },
    'model': {
        'hidden_dim': 128,
        'num_layers': 2
    },
    'data': {
        'dataset_name': 'test_dataset',
        'num_workers': 4
    }
}

config_file = configs_dir / 'test_config.yml'
with open(config_file, 'w') as f:
    yaml.dump(config_data, f)

# Create args namespace with some parameters matching config keys
# and some new parameters not in config
args = Namespace(
    config_name='test_config',
    learning_rate=0.002,
    batch_size=64,
    hidden_dim=256,
    new_param='new_value',
    another_param=None,
    unset_param=None
)

ARGS = {
    'args': args,
    'project_dir': project_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
yaml — 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
calc_aug_loss Not yet run
unverified (harvested, no recorded run)
mvandenhi/sctree-public/src/sctree/utils/training_utils.py
code served (permissive licence) · get_code("32a03166f0d6d67c")
How it ran

no invocation recorded.

move_to Not yet run
unverified (harvested, no recorded run)
mvandenhi/sctree-public/src/sctree/utils/training_utils.py
code served (permissive licence) · get_code("a046b50a34886842")
How it ran

no invocation recorded.

predict Not yet run
unverified (harvested, no recorded run)
mvandenhi/sctree-public/src/sctree/utils/training_utils.py
code served (permissive licence) · get_code("e018da21b0bd6354")
How it ran

no invocation recorded.

return_list_tree Not yet run
unverified (harvested, no recorded run)
mvandenhi/sctree-public/src/sctree/utils/model_utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from JoGo175/diffuse-treevae, is pointer only (licence: NONE) · get_code("b942e816ea4942b4")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from JoGo175/diffuse-treevae, 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. No invocation recorded.

Also present in other papers' code

Of 10 samples lifted from this paper's linked repositories, 10 carry a function identity and 0 do not. Of the 10 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 7 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
compute_posterior 1 other paper
1 later
2407.06124 (2024-07)
Structured Generations: Using Hierarchical Clusters to guide Diffusion Models
construct_tree 1 other paper
1 later
2407.06124 (2024-07)
Structured Generations: Using Hierarchical Clusters to guide Diffusion Models
return_list_tree 1 other paper
1 later
2407.06124 (2024-07)
Structured Generations: Using Hierarchical Clusters to guide Diffusion Models

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

Repositories linked to this paper

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

Abstract

We propose a novel method, scTree, for single-cell Tree Variational Autoencoders, extending a hierarchical clustering approach to single-cell RNA sequencing data. scTree corrects for batch effects while simultaneously learning a tree-structured data representation. This VAE-based method allows for a more in-depth understanding of complex cellular landscapes independently of the biasing effects of batches. We show empirically on seven datasets that scTree discovers the underlying clusters of the data and the hierarchical relations between them, as well as outperforms established baseline methods across these datasets. Additionally, we analyze the learned hierarchy to understand its biological relevance, thus underpinning the importance of integrating batch correction directly into the clustering procedure.

For agents

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

get_harvested_code_for_paper("2406.19300")
get_code_for_paper("2406.19300")
have("2406.19300")

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

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

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

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

Connect an agent — have() is free.