SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2212.03281 · 2022

Copula Conformal Prediction for Multi-step Time Series Forecasting

arXiv · PDF · Open in the Atlas

Code that ran

3 of 4 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 3 have no contract verdict; 0 failures of our instrument; 1 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/2212.03281.json · badge: /api/ran/2212.03281.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
rose-stl-lab/copulacpts canonical (classifier label)
classifier basis not recorded on the link
3 ran · 1 no recorded run
FunctionStatusWhere it lives
create_inout_sequences Ran
ran on a synthesized input
rose-stl-lab/copulacpts/src/models/transformer.py
code served (permissive licence) · get_code("b6b4f5ec645e471d")
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 3, dtype family float, shape (5, 2, 7) 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

torch.manual_seed(0)

# Analyze the function:
# - input_data: needs len() and indexing with slices, should be array-like
# - tw: an integer (time window)
# - The function creates sequences by slicing input_data[i:i+tw]
# - output_window is a global set to 5
# - Returns a FloatTensor of tuples

output_window = 5

# Create a small input_data array
# Make it long enough: need L - tw > 0, so if tw=7, need L > 7
# Let's use L=12, tw=7 to have some sequences
input_data = 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])

# Time window parameter
tw = 7

ARGS = {
    "input_data": input_data,
    "tw": tw
}
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 Tensor, ndim 3, dtype family float, shape (5, 2, 7) — shape (5, 2, 7) 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_batch Ran
ran on a synthesized input
rose-stl-lab/copulacpts/src/models/transformer.py
code served (permissive licence) · get_code("527d95ed5bba9874")
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, ndim 4, 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 torch

torch.manual_seed(0)

# Analyze the function:
# - source: needs to be indexable, contains items where each item is a tuple of (data, target)
#   each data and target should be stackable tensors
# - i: integer index
# - batch_size: integer controlling sequence length

# The function does:
# source[i:i + seq_len] -> gets a slice of items
# item[0] and item[1] -> accesses first and second elements of each item
# torch.stack on those -> stacks them into tensors
# .chunk(input_window, 1) -> chunks along dimension 1
# torch.stack again on the chunks

# So source should be a list of tuples, where each tuple is (tensor, tensor)
# The tensors need to have dimension >= 2 (since we chunk on dim 1)
# and have a size divisible by input_window (100) along dim 1

input_window = 100
batch_size = 10

# Create source as a list of (input_tensor, target_tensor) pairs
# Each tensor needs to be chunked by input_window=100 along dim 1
# So dim 1 should be at least 100
# Let's make it exactly 100 for simplicity, shape (batch_size, 100)
# But actually looking closer: we stack item[0] for each item, so each item[0] should be 1D or 2D
# After stacking multiple items, we get a 2D tensor, then chunk on dim 1

# Let's trace through:
# data = source[i:i+seq_len] where seq_len <= batch_size
# [item[0] for item in data] is a list of tensors
# torch.stack(...) creates shape (seq_len, ...)
# .chunk(input_window, 1) chunks on dim 1, so we need dim 1 to exist and be divisible by input_window

# Simple approach: make each item[0] and item[1] be 1D tensors of size 100
# Then stack gives (seq_len, 100)
# Then chunk(100, 1) gives 100 chunks of size (seq_len, 1)
# Then stack those gives (100, seq_len, 1)

source = []
for _ in range(batch_size + 10):  # Make it longer than we'll use
    input_tensor = torch.randn(100)
    target_tensor = torch.randn(100)
    source.append((input_tensor, target_tensor))

ARGS = {
    "source": source,
    "i": 0,
    "batch_size": batch_size,
}
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, ndim 4, dtype family float — a tuple 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
gumbel_copula_loss Ran
ran on a synthesized input
rose-stl-lab/copulacpts/src/models/utils.py
code served (permissive licence) · get_code("5464052c539185b4")
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 (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 numpy as np

class MockCopula:
    def cdf(self, values):
        # The function calls cop.cdf([x] * data.shape[1])
        # which creates a list of repeated values
        # cdf should return a scalar or array-like value
        return np.array([0.5])

# Set up the arguments
x = 2.5
cop = MockCopula()
data = np.random.randn(2, 4)  # batch_size=2, features=4
epsilon = 0.1

ARGS = {
    "x": x,
    "cop": cop,
    "data": data,
    "epsilon": epsilon
}
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 ndarray, 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
plot_and_loss Not yet run
unverified (harvested, no recorded run)
rose-stl-lab/copulacpts/src/models/transformer.py
code served (permissive licence) · get_code("ac21c545e16f6631")
How it ran

no invocation recorded.

Also present in other papers' code

Of 4 samples lifted from this paper's linked repositories, 4 carry a function identity and 0 do not. Of the 4 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 4 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

Accurate uncertainty measurement is a key step to building robust and reliable machine learning systems. Conformal prediction is a distribution-free uncertainty quantification algorithm popular for its ease of implementation, statistical coverage guarantees, and versatility for underlying forecasters. However, existing conformal prediction algorithms for time series are limited to single-step prediction without considering the temporal dependency. In this paper, we propose a Copula Conformal Prediction algorithm for multivariate, multi-step Time Series forecasting, CopulaCPTS. We prove that CopulaCPTS has finite sample validity guarantee. On several synthetic and real-world multivariate time series datasets, we show that CopulaCPTS produces more calibrated and sharp confidence intervals for multi-step prediction tasks than existing techniques.

For agents

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

get_harvested_code_for_paper("2212.03281")
get_code_for_paper("2212.03281")
have("2212.03281")

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

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

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

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

Connect an agent — have() is free.