SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2206.08107 · ICML · 2022

Closed-Form Diffeomorphic Transformations for Time Series Alignment

I Ñigo Martinez, Elisabeth Viles, Igor Olaizola

arXiv · PDF · Open in the Atlas

Code that ran

2 of 2 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (2 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 2 have no contract verdict; 0 failures of our instrument; 0 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/2206.08107.json · badge: /api/ran/2206.08107.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
imartinezl/difw canonical (classifier label)
classifier basis: classifier_2025
2 ran · 0 no recorded run
FunctionStatusWhere it lives
Transformer_fast_gpu_closed_form Ran
ran on a synthesized input · constructed an object; no result was computed
imartinezl/difw/difw/backend/pytorch/transformer.py
code served (permissive licence) · get_code("beebe3003d90d3ce")
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, Transformer_fast_gpu_closed_form: 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.nn as nn

torch.manual_seed(0)

# Define a mock params object with required attributes
class MockParams:
    def __init__(self):
        self.B = 2  # batch size
        self.xmin = 0.0
        self.xmax = 1.0
        self.nc = 4  # number of channels

# Create a mock cpab_gpu object with required methods
class MockCPABGPU:
    def integrate_closed_form_trace(self, grid, theta, time, B, xmin, xmax, nc):
        # Should return shape [batch, spatial_dim, 1] based on grid_t = output[:, :, 0]
        batch_size = grid.shape[0]
        spatial_dim = grid.shape[1]
        return torch.randn(batch_size, spatial_dim, 1)
    
    def derivative_closed_form_trace(self, output, grid, theta, B, xmin, xmax, nc):
        # Should return shape compatible with permute(2, 0, 1)
        # After permute(2, 0, 1), it becomes [1, batch, spatial]
        batch_size = grid.shape[0]
        spatial_dim = grid.shape[1]
        return torch.randn(batch_size, spatial_dim, 1)
    
    def derivative_space_closed_form(self, grid, theta, time, B, xmin, xmax, nc):
        # Should match grad_output shape for multiplication
        batch_size = grid.shape[0]
        spatial_dim = grid.shape[1]
        return torch.randn(batch_size, spatial_dim)

# Replace the global cpab_gpu with our mock
cpab_gpu = MockCPABGPU()

# Create test tensors
batch_size = 2
spatial_dim = 4
theta_dim = 3

grid = torch.randn(batch_size, spatial_dim)
theta = torch.randn(batch_size, theta_dim, requires_grad=True)
params = MockParams()

ARGS = {
    'grid': grid,
    'theta': theta,
    'params': params,
    'time': 1.0
}
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 Transformer_fast_gpu_closed_form — 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 Transformer_fast_gpu_closed_form 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
_notcompiled Ran
ran on a synthesized input · constructed an object; no result was computed
imartinezl/difw/difw/backend/pytorch/transformer.py
code served (permissive licence) · get_code("0889a4a195de60df")
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, _notcompiled: 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.nn as nn

torch.manual_seed(0)

class _notcompiled:

    def __init__(self):

        def f(*args):
            return None
        self.forward = f
        self.backward = f


# The __init__ method takes no parameters besides self
# It defines two internal functions (f) and assigns them to self.forward and self.backward
# No external arguments are needed

ARGS = {}
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 _notcompiled — 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 _notcompiled 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

Also present in other papers' code

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

Time series alignment methods call for highly expressive, differentiable and invertible warping functions which preserve temporal topology, i.e diffeomorphisms. Diffeomorphic warping functions can be generated from the integration of velocity fields governed by an ordinary differential equation (ODE). Gradient-based optimization frameworks containing diffeomorphic transformations require to calculate derivatives to the differential equation's solution with respect to the model parameters, i.e. sensitivity analysis. Unfortunately, deep learning frameworks typically lack automatic-differentiation-compatible sensitivity analysis methods; and implicit functions, such as the solution of ODE, require particular care. Current solutions appeal to adjoint sensitivity methods, ad-hoc numerical solvers or ResNet's Eulerian discretization. In this work, we present a closed-form expression for the ODE solution and its gradient under continuous piecewise-affine (CPA) velocity functions. We present a highly optimized implementation of the results on CPU and GPU. Furthermore, we conduct extensive experiments on several datasets to validate the generalization ability of our model to unseen data for time-series joint alignment. Results show significant improvements both in terms of efficiency and accuracy.

For agents

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

get_harvested_code_for_paper("2206.08107")
get_code_for_paper("2206.08107")
have("2206.08107")

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

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

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

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

Connect an agent — have() is free.