SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1306.6802 · 2013

Evaluation Measures for Hierarchical Classification: a unified view and novel approaches

arXiv · PDF · Open in the Atlas

Code that ran

16 of 17 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 16 have no contract verdict; 0 failures of our instrument; 1 no recorded run), measured 2026-11-21; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/1306.6802.json · badge: /api/ran/1306.6802.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
fbenites/sklearn-hierarchical-classification community (classifier label)
classifier basis not recorded on the link
11 ran · 0 no recorded run
globality-corp/sklearn-hierarchical-classification community (classifier label)
classifier basis not recorded on the link
5 ran · 1 no recorded run
FunctionStatusWhere it lives
apply_along_rows Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/array.py
code served (permissive licence) · get_code("a7a7ed3dfc53de37")
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 MaskedArray, 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 numpy as np
from scipy.sparse import csr_matrix

def dummy_func(x):
    """Simple function that works with both dense and sparse inputs."""
    if hasattr(x, 'toarray'):
        # sparse matrix
        return np.sum(x.toarray())
    else:
        # dense array
        return np.sum(x)

# Create a small dense matrix (4 rows, 3 columns)
dense_matrix = np.array([
    [1.0, 2.0, 3.0],
    [4.0, 5.0, 6.0],
    [7.0, 8.0, 9.0],
    [10.0, 11.0, 12.0]
])

# Create a small sparse matrix (4 rows, 3 columns)
sparse_matrix = csr_matrix(dense_matrix)

ARGS = {
    "func": dummy_func,
    "X": dense_matrix
}
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 MaskedArray, 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
apply_along_rows Ran
ran on a synthesized input
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/array.py
code served (permissive licence) · get_code("c438ab5681bb1630")
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 MaskedArray, 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 numpy as np
from scipy.sparse import csr_matrix

def simple_func(x):
    """A simple function that works on row vectors (1D arrays or sparse matrices)"""
    if isinstance(x, csr_matrix):
        return x.sum()
    else:
        return np.sum(x)

# Create a dense matrix (4 rows, 3 columns)
dense_matrix = np.array([
    [1.0, 2.0, 3.0],
    [4.0, 5.0, 6.0],
    [7.0, 8.0, 9.0],
    [10.0, 11.0, 12.0]
])

# Create a sparse CSR matrix (4 rows, 3 columns)
sparse_matrix = csr_matrix(np.array([
    [1, 0, 3],
    [0, 5, 0],
    [7, 0, 9],
    [0, 11, 0]
], dtype=float))

ARGS = {
    "func": simple_func,
    "X": dense_matrix
}
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 MaskedArray, 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
apply_rollup_Xy Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/array.py
code served (permissive licence) · get_code("5978231e213ac4cb")
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
from scipy.sparse import csr_matrix

# Create a simple sparse matrix X with shape (2, 4)
# This represents 2 samples with 4 features
X_dense = np.array([
    [1, 0, 2, 0],
    [0, 3, 0, 4]
], dtype=np.float32)
X = csr_matrix(X_dense)

# Create y as a list-of-lists where each sample has a list of labels
# Sample 0 has labels [0, 1] (so it appears twice in output)
# Sample 1 has labels [2] (so it appears once in output)
y = [[0, 1], [2]]

ARGS = {
    "X": X,
    "y": y
}
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 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
apply_rollup_Xy Ran
ran on a synthesized input
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/array.py
code served (permissive licence) · get_code("74355edadce3939c")
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
from scipy.sparse import csr_matrix

# Create a small sparse matrix X with shape (2, 4)
# We'll create it from dense first, then convert to sparse
X_dense = np.array([
    [1, 0, 2, 0],
    [0, 3, 0, 4]
], dtype=np.float32)
X = csr_matrix(X_dense)

# Create y as a list-of-lists where each inner list contains labels for that sample
# Sample 0 should be used for 2 labels, sample 1 should be used for 1 label
y = [[0, 1], [2]]

ARGS = {
    "X": X,
    "y": y
}
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 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
fill_ancestors Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/metrics.py
code served (permissive licence) · get_code("9a75ea148d2f9d75")
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 int, 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 numpy as np
import networkx as nx

# Create a small directed graph representing a class hierarchy
graph = nx.DiGraph()
graph.add_edges_from([
    (0, 1),  # 0 is parent of 1
    (1, 2),  # 1 is parent of 2
    (0, 3),  # 0 is parent of 3
])

# Create a binary matrix of shape [n_samples=2, n_classes=4]
# Each row represents which classes a sample belongs to
y = np.array([
    [0, 1, 0, 0],  # sample 0: belongs to class 1
    [0, 0, 1, 0],  # sample 1: belongs to class 2
], dtype=np.int64)

ARGS = {
    "y": y,
    "graph": graph,
    "copy": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx, numpy — 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 int, 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
flatten_list Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/array.py
code served (permissive licence) · get_code("46c4baefb00ca6da")
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 int; 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 torch
import numpy as np
from itertools import chain

torch.manual_seed(0)

# The function flatten_list takes a single parameter 'lst'
# It expects an iterable of iterables and flattens them using chain
# Create a simple nested list structure with distinct dimensions

lst = [
    [1, 2, 3],
    [4, 5],
    [6, 7, 8, 9]
]

ARGS = {
    "lst": lst
}
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 list, ndim 1, dtype family int — 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
h_precision_score Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/metrics.py
code served (permissive licence) · get_code("a3540498c7bff102")
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
import networkx as nx

# Create a small class hierarchy graph
# Nodes: 0, 1, 2, 3 (4 classes)
# Edges represent parent-child relationships in the hierarchy
graph = nx.DiGraph()
graph.add_edges_from([
    (0, 1),  # 0 is parent of 1
    (0, 2),  # 0 is parent of 2
    (1, 3),  # 1 is parent of 3
])

# Create y_true: 2 samples, 4 classes
# Sample 0: classes 1 and 3 are true
# Sample 1: class 2 is true
y_true = np.array([
    [0, 1, 0, 1],
    [0, 0, 1, 0]
], dtype=int)

# Create y_pred: 2 samples, 4 classes
# Sample 0: classes 1 and 2 are predicted
# Sample 1: classes 0 and 3 are predicted
y_pred = np.array([
    [0, 1, 1, 0],
    [1, 0, 0, 1]
], dtype=int)

ARGS = {
    "y_true": y_true,
    "y_pred": y_pred,
    "class_hierarchy": graph,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx, numpy — 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
h_recall_score Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/metrics.py
code served (permissive licence) · get_code("ef0794922f8e6a63")
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
import networkx as nx

# Create a simple class hierarchy graph
# Nodes: 0, 1, 2, 3
# Edges: 0 -> 1, 0 -> 2, 1 -> 3 (representing parent-child relationships)
graph = nx.DiGraph()
graph.add_edges_from([(0, 1), (0, 2), (1, 3)])

# Create y_true: shape [n_samples=2, n_classes=4]
# Row 0: class 3 is true
# Row 1: class 2 is true
y_true = np.array([
    [0, 0, 0, 1],
    [0, 0, 1, 0]
], dtype=int)

# Create y_pred: shape [n_samples=2, n_classes=4]
# Row 0: class 1 and 3 are predicted
# Row 1: class 2 is predicted
y_pred = np.array([
    [0, 1, 0, 1],
    [0, 0, 1, 0]
], dtype=int)

ARGS = {
    'y_true': y_true,
    'y_pred': y_pred,
    'class_hierarchy': graph
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx, numpy — 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
is_estimator Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/validation.py
code served (permissive licence) · get_code("f6577bee67e69780")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
from torch import nn

torch.manual_seed(0)

# Create a simple class with a fit method (a valid estimator)
class SimpleEstimator:
    def fit(self, X, y):
        return self

# Create a simple class without a fit method (not an estimator)
class NotAnEstimator:
    def predict(self, X):
        return X

# Create an nn.Module with a fit method (also a valid estimator)
class NNEstimator(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 2)
    
    def forward(self, x):
        return self.linear(x)
    
    def fit(self, X, y):
        return self

# Test with an object that has a fit method
estimator_obj = SimpleEstimator()

ARGS = {
    'obj': estimator_obj
}
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 bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
logger Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/decorators.py
code served (permissive licence) · get_code("24fe396d1811877a")
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 type. 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
from logging import getLogger

torch.manual_seed(0)

# The logger function takes an object and assigns it a logger property
# based on the object's __name__ attribute. The function works on classes.

class SampleClass:
    pass

# Rename to match what getLogger expects
SampleClass.__name__ = "SampleClass"

ARGS = {
    "obj": SampleClass
}
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 type — a type output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a type 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
logger Ran
ran on a synthesized input
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/decorators.py
code served (permissive licence) · get_code("61994a011b1cf8d5")
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 type. 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 logging import getLogger

# The logger decorator is designed to work on classes
# It accesses obj.__name__ to get the class name and assigns a logger to it
# Let's create a simple test class to decorate

class TestClass:
    pass

ARGS = {
    "obj": TestClass
}
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 type — a type output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a type 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
make_flat_hierarchy Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/graph.py
code served (permissive licence) · get_code("db6c3509919eb91c")
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 defaultdict. 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.

from collections import defaultdict

# Analyze the function:
# - targets: an iterable of items to be added to the hierarchy
# - root: a single node that serves as the root
# The function iterates over targets and appends each to adjacency[root]
# So targets should be an iterable and root should be a hashable value

ARGS = {
    "targets": ["node1", "node2", "node3"],
    "root": "root_node"
}
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 defaultdict — a defaultdict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a defaultdict 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
make_flat_hierarchy Ran
ran on a synthesized input
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/graph.py
code served (permissive licence) · get_code("469dd58aeafd18fc")
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 defaultdict. 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.

from collections import defaultdict

torch_seed = 0
import torch
torch.manual_seed(torch_seed)

# Analyzing the function:
# - targets: iterable of items to be added as values in the adjacency dict
# - root: a key that will be used in the adjacency dict
# The function creates a defaultdict(list) and appends each target to adjacency[root]
# So targets should be an iterable and root should be a hashable key

targets = ['node_1', 'node_2', 'node_3']
root = 'root_node'

ARGS = {
    'targets': targets,
    'root': root
}
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 defaultdict — a defaultdict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a defaultdict 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
rollup_nodes Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/graph.py
code served (permissive licence) · get_code("422ba2af0df6008e")
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. 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 networkx as nx
from networkx import all_simple_paths

# Create a simple directed graph for testing
graph = nx.DiGraph()

# Add nodes
graph.add_nodes_from([0, 1, 2, 3, 4, 5])

# Add edges to create paths from source (0) to targets
# Path structure: 0 -> 1 -> 3 -> 5
#                 0 -> 2 -> 4 -> 5
graph.add_edges_from([
    (0, 1),
    (1, 3),
    (3, 5),
    (0, 2),
    (2, 4),
    (4, 5),
])

source = 0
targets = [5, 3]

ARGS = {
    "graph": graph,
    "source": source,
    "targets": targets,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list — a list 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
rollup_nodes Ran
ran on a synthesized input
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/graph.py
code served (permissive licence) · get_code("fda4b7a4196ed395")
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 2, dtype family int; 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 networkx as nx

# Create a simple directed graph for testing
# We need a graph with a source node, target nodes, and paths between them
graph = nx.DiGraph()

# Add edges to create a graph structure:
# source (0) -> node1 (1) -> target1 (3)
# source (0) -> node2 (2) -> target2 (4)
# This ensures all_simple_paths can find paths from source to targets
graph.add_edges_from([
    (0, 1),  # source to node1
    (1, 3),  # node1 to target1
    (0, 2),  # source to node2
    (2, 4),  # node2 to target2
])

source = 0
targets = [3, 4]

ARGS = {
    "graph": graph,
    "source": source,
    "targets": targets,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 2, dtype family int — 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
root_nodes Ran
ran on a synthesized input
fbenites/sklearn-hierarchical-classification/sklearn_hierarchical_classification/graph.py
code served (permissive licence) · get_code("976ef00f1dedd5f4")
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 generator. 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 networkx as nx

# Create a small directed graph with some root nodes (in_degree == 0)
graph = nx.DiGraph()

# Add nodes
graph.add_nodes_from([1, 2, 3, 4, 5])

# Add edges to create structure
# Node 1 and 2 have in_degree 0 (root nodes)
# Node 3 points to node 4
# Node 2 points to node 5
graph.add_edge(1, 3)
graph.add_edge(2, 4)
graph.add_edge(2, 5)

ARGS = {
    "graph": graph
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type generator — a generator output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a generator 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
fill_ancestors Not yet run
unverified (harvested, no recorded run)
globality-corp/sklearn-hierarchical-classification/sklearn_hierarchical_classification/metrics.py
code served (permissive licence) · get_code("471aa6e2394887ce")
How it ran

no invocation recorded.

Also present in other papers' code

Of 17 samples lifted from this paper's linked repositories, 17 carry a function identity and 0 do not. Of the 12 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 12 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-21.

Repositories linked to this paper

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

Abstract

Hierarchical classification addresses the problem of classifying items into a hierarchy of classes. An important issue in hierarchical classification is the evaluation of different classification algorithms, which is complicated by the hierarchical relations among the classes. Several evaluation measures have been proposed for hierarchical classification using the hierarchy in different ways. This paper studies the problem of evaluation in hierarchical classification by analyzing and abstracting the key components of the existing performance measures. It also proposes two alternative generic views of hierarchical evaluation and introduces two corresponding novel measures. The proposed measures, along with the state-of-the art ones, are empirically tested on three large datasets from the domain of text classification. The empirical results illustrate the undesirable behavior of existing approaches and how the proposed methods overcome most of these methods across a range of cases.

For agents

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

get_harvested_code_for_paper("1306.6802")
get_code_for_paper("1306.6802")
have("1306.6802")

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

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

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

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

Connect an agent — have() is free.