SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1702.00748 · 2017

QCD-Aware Recursive Neural Networks for Jet Physics

arXiv · PDF · Open in the Atlas

Code that ran

9 of 15 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 9 have no contract verdict; 0 failures of our instrument; 6 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/1702.00748.json · badge: /api/ran/1702.00748.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
glouppe/recnn canonical (classifier label)
classifier basis: census
6 ran · 0 no recorded run
SebastianMacaluso/RecNN_PyTorch community (classifier label)
classifier basis not recorded on the link
3 ran · 4 no recorded run
diana-hep/treenin reimplementation (classifier label)
classifier basis: classifier_2025
0 ran · 1 no recorded run
sebastianmacaluso/treenin community (classifier label)
classifier basis not recorded on the link
0 ran · 1 no recorded run
FunctionStatusWhere it lives
batch Ran
ran on a synthesized input
glouppe/recnn/recnn/recnn.py
code served (permissive licence) · get_code("c0889f46048db603")
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 autograd.numpy as np

def create_simple_jet(root_id, num_nodes):
    """Create a minimal jet dict with tree structure and content."""
    tree = np.full((num_nodes, 2), -1, dtype=np.int32)
    
    # Create a simple binary tree structure
    if num_nodes > 1:
        tree[0, 0] = 1  # node 0 has left child at index 1
        if num_nodes > 2:
            tree[0, 1] = 2  # node 0 has right child at index 2
    
    content = np.random.randn(num_nodes, 4).astype(np.float32)
    
    return {
        'tree': tree,
        'content': content,
        'root_id': root_id
    }

# Create two simple jets for batching
jet1 = create_simple_jet(0, 3)
jet2 = create_simple_jet(0, 4)

jets = [jet1, jet2]

ARGS = {
    'jets': jets
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
autograd — 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
customized_collate Ran
ran on a synthesized input
SebastianMacaluso/RecNN_PyTorch/code/recnn/model/dataset.py
code served (permissive licence) · get_code("5921652846309c44")
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

torch.manual_seed(0)

# Construct a batch with 1 sample, where each sample is a tuple of 6 elements
# The function accesses batch[0][0] through batch[0][5]

sample = (
    [1, 2, 3, 4],  # levels - list of 4 integers
    [0, 1, 1, 2],  # children - list of 4 integers
    [2, 1, 0, 1],  # n_inners - list of 4 integers
    [0.1, 0.2, 0.3, 0.4],  # contents - list of 4 floats
    [3],  # n_level - list with 1 integer
    [1],  # labels - list with 1 integer
)

batch = [sample]

ARGS = {
    "batch": batch
}
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 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
load_from_pickle Ran
ran on a synthesized input
glouppe/recnn/recnn/preprocessing.py
code served (permissive licence) · get_code("863867e0a01794b3")
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 list, ndim 1, 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 pickle
import tempfile
import os

# Create a temporary pickle file with some test data
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "test_jets.pkl")

# Write some dummy jet data to the pickle file
with open(temp_file, 'wb') as f:
    pickle.dump({"jet": 1, "data": [1, 2, 3]}, f)
    pickle.dump({"jet": 2, "data": [4, 5, 6]}, f)
    pickle.dump({"jet": 3, "data": [7, 8, 9]}, f)

ARGS = {
    "filename": temp_file,
    "n_jets": 3
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
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
permute_by_pt Ran
ran on a synthesized input
glouppe/recnn/recnn/preprocessing.py
code served (permissive licence) · get_code("ced2098d669afa6f")
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 numpy as np

# Construct a minimal jet structure that satisfies the function's requirements
# The function expects:
# - jet['root_id']: an integer index
# - jet['tree']: a list/array where each element is [left_child, right_child]
#   (-1 indicates leaf node)
# - jet['content']: a list/array where each element is a vector [x, y, z, ...]

# Build a simple binary tree with 7 nodes (indices 0-6)
# Node 0 is root with children 1 and 2
# Node 1 has children 3 and 4
# Node 2 has children 5 and 6
# Nodes 3-6 are leaves

jet = {
    'root_id': 0,
    'tree': [
        [1, 2],        # node 0: children are 1 and 2
        [3, 4],        # node 1: children are 3 and 4
        [5, 6],        # node 2: children are 5 and 6
        [-1, -1],      # node 3: leaf
        [-1, -1],      # node 4: leaf
        [-1, -1],      # node 5: leaf
        [-1, -1],      # node 6: leaf
    ],
    'content': [
        np.array([1.0, 0.5, 2.0, 0.0]),   # node 0
        np.array([0.8, 0.3, 1.5, 0.0]),   # node 1
        np.array([0.6, 0.2, 1.2, 0.0]),   # node 2
        np.array([0.4, 0.1, 0.8, 0.0]),   # node 3
        np.array([0.3, 0.2, 0.9, 0.0]),   # node 4
        np.array([0.5, 0.15, 1.0, 0.0]),  # node 5
        np.array([0.2, 0.1, 0.6, 0.0]),   # node 6
    ]
}

ARGS = {
    'jet': jet,
    'root_id': None
}
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 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
permute_by_pt Ran
ran on a synthesized input
SebastianMacaluso/RecNN_PyTorch/code/recnn/model/preprocess.py
code served (permissive licence) · get_code("873f80f593b759d3")
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)

# Build a jet structure that the function expects
# The function accesses:
# - jet['root_id']: an integer index
# - jet['tree']: a list/array where tree[i] = [left_child_idx, right_child_idx]
# - jet['content']: a list/array where content[i] is a vector with at least 2 elements

# Create a simple binary tree structure
# Node indices: 0 (root), 1 (left), 2 (right)
jet = {
    'root_id': 0,
    'tree': [
        [1, 2],      # node 0: left=1, right=2
        [-1, -1],    # node 1: leaf
        [-1, -1]     # node 2: leaf
    ],
    'content': [
        np.array([3.0, 4.0, 0.0, 0.0]),  # node 0: pt = sqrt(9+16) = 5.0
        np.array([1.0, 1.0, 0.0, 0.0]),  # node 1: pt = sqrt(1+1) ≈ 1.414
        np.array([2.0, 1.0, 0.0, 0.0])   # node 2: pt = sqrt(4+1) ≈ 2.236
    ]
}

ARGS = {
    'jet': jet,
    'root_id': None
}
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
relu Ran
ran on a synthesized input
glouppe/recnn/recnn/recnn.py
code served (permissive licence) · get_code("ef94bdd1ea899a09")
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 1, dtype family float, shape (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 autograd.numpy as np

# The function relu takes two parameters: x and alpha
# x should be a numeric array-like object that supports abs() and arithmetic operations
# alpha should be a numeric value (default 0.0)

# Create a small test input array
x_input = np.array([-2.0, -1.0, 0.5, 2.0])

# Test with alpha = 0.0 (standard ReLU)
alpha_value = 0.0

ARGS = {
    "x": x_input,
    "alpha": alpha_value
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
autograd — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 1, dtype family float, shape (4,) — shape (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
rewrite_content Ran
ran on a synthesized input
glouppe/recnn/recnn/preprocessing.py
code served (permissive licence) · get_code("e876f508b96d2de0")
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
import copy

torch.manual_seed(0)

# The function expects a dict with keys: 'content', 'tree', 'root_id'
# content: numpy array with shape (n_nodes, features) where features can be 4 or 5
# tree: numpy array with shape (n_nodes, 2) containing child indices
# root_id: integer index of root node

# Create a small tree structure with 3 nodes
# Node structure: parent has children at indices 1 and 2, leaves are 1 and 2
n_nodes = 3
n_features = 5

# Create content array (n_nodes x n_features)
# Using 5 features so the pflow copy logic is triggered
content = np.random.randn(n_nodes, n_features).astype(np.float32)

# Create tree array (n_nodes x 2)
# tree[i] = [left_child_idx, right_child_idx]
# For a simple tree: node 0 is root with children 1,2; nodes 1,2 are leaves (-1)
tree = np.array([
    [1, 2],      # node 0: children are 1 and 2
    [-1, -1],    # node 1: leaf node
    [-1, -1]     # node 2: leaf node
], dtype=np.int64)

jet = {
    'content': content,
    'tree': tree,
    'root_id': 0
}

ARGS = {
    'jet': jet
}
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
rewrite_content_leaves Ran
ran on a synthesized input
SebastianMacaluso/RecNN_PyTorch/code/recnn/model/preprocess.py
code served (permissive licence) · get_code("fd28d4c9d8d8a5bf")
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 numpy as np
import copy

# Create a minimal jet structure that the function expects
# The function expects:
# - jet['content']: some content (used only for len())
# - jet['tree']: a 2D array where tree[i, 0] and tree[i, 1] are indices or -1
# - jet['root_id']: integer index to start recursion from

# Build a simple tree structure with 5 nodes
# Node structure: internal nodes have children, leaf nodes have -1 for both children
tree = np.array([
    [-1, -1],  # node 0: leaf
    [-1, -1],  # node 1: leaf
    [0, 1],    # node 2: internal, children are 0 and 1
    [-1, -1],  # node 3: leaf
    [2, 3],    # node 4: internal (root), children are 2 and 3
], dtype=np.int32)

# content can be anything with a length; use a simple list
content = [1, 2, 3, 4, 5]

jet = {
    'content': content,
    'tree': tree,
    'root_id': 4  # start from the root node
}

ARGS = {
    'jet': jet
}
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 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
sigmoid Ran
ran on a synthesized input
glouppe/recnn/recnn/recnn.py
code served (permissive licence) · get_code("dd85f5245490cfbc")
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 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 autograd.numpy as np

# The sigmoid function takes a single parameter x
# It uses np.tanh and basic arithmetic operations on x
# x should be a numpy array (since we're using autograd.numpy)

x = np.array([[-1.0, 0.0, 1.0, 2.0],
              [0.5, -0.5, 1.5, -1.5]])

ARGS = {
    "x": x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
autograd — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, 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
accuracy Not yet run
unverified (harvested, no recorded run)
diana-hep/treenin/code/recnn/model/recNet.py
code served (permissive licence) · get_code("2577fdc8a1760636")
How it ran

no invocation recorded.

batch_array Not yet run
unverified (harvested, no recorded run)
SebastianMacaluso/RecNN_PyTorch/code/recnn/model/data_loader.py
code served (permissive licence) · get_code("c38dbb9df22822b2")
How it ran

no invocation recorded.

generate_results Not yet run
unverified (harvested, no recorded run)
SebastianMacaluso/RecNN_PyTorch/code/recnn/evaluate.py
code served (permissive licence) · get_code("3b1d105a12715a99")
How it ran

no invocation recorded.

load_checkpoint Not yet run
unverified (harvested, no recorded run)
SebastianMacaluso/RecNN_PyTorch/code/recnn/utils.py
code served (permissive licence) · get_code("86c1ce4e147ab620")
How it ran

no invocation recorded.

load_results Not yet run
unverified (harvested, no recorded run)
sebastianmacaluso/treenin/code/saveProb.py
code served (permissive licence) · get_code("aba2779c22a6dd3f")
How it ran

no invocation recorded.

metrics_to_table Not yet run
unverified (harvested, no recorded run)
SebastianMacaluso/RecNN_PyTorch/code/recnn/synthesize_results.py
code served (permissive licence) · get_code("08edc51cb8e89e31")
How it ran

no invocation recorded.

Also present in other papers' code

Of 15 samples lifted from this paper's linked repositories, 15 carry a function identity and 0 do not. Of the 15 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 15 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.

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

Recent progress in applying machine learning for jet physics has been built upon an analogy between calorimeters and images. In this work, we present a novel class of recursive neural networks built instead upon an analogy between QCD and natural languages. In the analogy, four-momenta are like words and the clustering history of sequential recombination jet algorithms is like the parsing of a sentence. Our approach works directly with the four-momenta of a variable-length set of particles, and the jet-based tree structure varies on an event-by-event basis. Our experiments highlight the flexibility of our method for building task-specific jet embeddings and show that recursive architectures are significantly more accurate and data efficient than previous image-based networks. We extend the analogy from individual jets (sentences) to full events (paragraphs), and show for the first time an event-level classifier operating on all the stable particles produced in an LHC event.

For agents

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

get_harvested_code_for_paper("1702.00748")
get_code_for_paper("1702.00748")
have("1702.00748")

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

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

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

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

Connect an agent — have() is free.