SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2503.21761 · CVPR · 2025

Uni4D: Unifying Visual Foundation Models for 4D Modeling from a Single Video

Shenlong Wang, David Yao, Albert Zhai

arXiv · PDF · Open in the Atlas

Code that ran

15 of 18 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 13 have no contract verdict; 1 failure of our instrument; 3 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/2503.21761.json · badge: /api/ran/2503.21761.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
Davidyao99/uni4d canonical (classifier label)
classifier basis not recorded on the link
15 ran · 3 no recorded run
FunctionStatusWhere it lives
absolute_error_loss Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/eval_depth.py
code served (permissive licence) · get_code("6dc0a401faa181c2")
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 float32, 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 numpy as np

# Construct small numpy arrays for depth predictions and ground truth
predicted_depth = np.random.randn(2, 4).astype(np.float32)
ground_truth_depth = np.random.randn(2, 4).astype(np.float32)

# Construct parameters: scale (s) and translation (t)
params = (1.5, 0.2)

ARGS = {
    "params": params,
    "predicted_depth": predicted_depth,
    "ground_truth_depth": ground_truth_depth,
}
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 float32, 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
absolute_value_scaling Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/eval_depth.py
code served (permissive licence) · get_code("071060ffd8045cf0")
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 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 torch
import numpy as np

torch.manual_seed(0)

# Create small tensor arguments for the function
# predicted_depth and ground_truth_depth should be tensors that can be converted to numpy
predicted_depth = torch.randn(2, 4)
ground_truth_depth = torch.randn(2, 4)

# Optional parameters s and t with default values
s = 1.0
t = 0.0

ARGS = {
    "predicted_depth": predicted_depth,
    "ground_truth_depth": ground_truth_depth,
    "s": s,
    "t": t
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, 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
convert_trajectory_to_extrinsic_matrices Ran
ran on a synthesized input
Davidyao99/uni4d/dataset_prepare/util.py
code served (permissive licence) · get_code("3470bb7f3951b38c")
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 3, dtype family float, shape (2, 4, 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.spatial.transform import Rotation

# Create small sample data
positions = np.array([
    [0.0, 0.0, 0.0],
    [1.0, 2.0, 3.0]
], dtype=np.float32)

# Create valid quaternions in xyzw format (scipy expects xyzw)
quaternions_xyzw = np.array([
    [0.0, 0.0, 0.0, 1.0],  # identity quaternion (x, y, z, w)
    [0.7071068, 0.0, 0.0, 0.7071068]  # 90 degree rotation around x-axis
], dtype=np.float32)

ARGS = {
    "positions": positions,
    "quaternions_xyzw": quaternions_xyzw
}
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 ndarray, ndim 3, dtype family float, shape (2, 4, 4) — shape (2, 4, 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
depth2disparity Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/eval_depth.py
code served (permissive licence) · get_code("7d031b19941d06f5")
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 numpy as np

torch.manual_seed(0)

# Test with torch.Tensor
depth_tensor = torch.rand(2, 4)
depth_tensor[0, 0] = 0  # Add a zero value to test masking

# Test with numpy.ndarray
depth_numpy = np.random.rand(2, 4).astype(np.float32)
depth_numpy[0, 0] = 0  # Add a zero value to test masking

ARGS = {
    "depth": depth_tensor,
    "return_mask": False,
}
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 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
depth_read Ran
ran, honoured the contract we drafted
Davidyao99/uni4d/dataset_prepare/sintel_io.py
code served (permissive licence) · get_code("a88685769d5ff548")
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 (3, 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 tempfile
import os

TAG_FLOAT = 202021.25

# Create a temporary depth file for testing
temp_dir = tempfile.mkdtemp()
temp_filename = os.path.join(temp_dir, "test_depth.bin")

# Write a valid depth file
width = 4
height = 3
depth_data = np.random.rand(height, width).astype(np.float32)

with open(temp_filename, 'wb') as f:
    np.array([TAG_FLOAT], dtype=np.float32).tofile(f)
    np.array([width], dtype=np.int32).tofile(f)
    np.array([height], dtype=np.int32).tofile(f)
    depth_data.tofile(f)

ARGS = {
    'filename': temp_filename
}
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 2, dtype family float, shape (3, 4) — shape (3, 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
depth_vis Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/util.py
code served (permissive licence) · get_code("0cbc9f11c671557a")
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 3, 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 cv2
import numpy as np
import torch

torch.manual_seed(0)

# Create a small depth map for testing
# The function expects a 2D or 3D array-like object with min/max operations
depth_map = np.random.rand(4, 3).astype(np.float32) * 10

ARGS = {
    "depth_map": depth_map
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 3, dtype family int — no output shape is stated: observe_signature.py could not observe it (no_result)
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
disparity_read Ran
ran on a synthesized input
Davidyao99/uni4d/dataset_prepare/sintel_io.py
code served (permissive licence) · get_code("e162442d5908bd04")
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 (4, 3) 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 PIL import Image
import tempfile
import os

# Create a temporary disparity image file
# The function expects an image with 3 channels (RGB)
# disparity = R * 4 + G / 64 + B / 16384

# Create a small test image (4x3 pixels, 3 channels)
disparity_data = np.zeros((4, 3, 3), dtype=np.uint8)

# Set some test values
# R channel: contributes most significantly (multiplied by 4)
disparity_data[:, :, 0] = 10  # Red channel
# G channel: contributes less (divided by 64)
disparity_data[:, :, 1] = 32  # Green channel
# B channel: contributes least (divided by 16384)
disparity_data[:, :, 2] = 64  # Blue channel

# Create a PIL Image and save it to a temporary file
img = Image.fromarray(disparity_data, mode='RGB')
temp_file = tempfile.NamedTemporaryFile(suffix='.png', delete=False)
temp_filename = temp_file.name
temp_file.close()

img.save(temp_filename)

# Define the arguments dictionary
ARGS = {
    'filename': temp_filename
}

# Clean up will happen after function execution
# (In practice, you'd want to handle cleanup, but for this setup it's sufficient)
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, 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 float, shape (4, 3) — shape (4, 3) 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
find_closest_index Ran
ran on a synthesized input
Davidyao99/uni4d/dataset_prepare/preprocess_tumd.py
code served (permissive licence) · get_code("959323d9f907ca0b")
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 int, ndim 0, dtype family int, 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

# Create a sorted list of numbers for testing
L = [1.5, 3.2, 5.7, 8.1, 10.3, 12.9, 15.4]

# Create a target value
t = 5.5

ARGS = {
    'L': L,
    't': t
}
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 int, ndim 0, dtype family int, 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
flow_norm Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/util.py
code served (permissive licence) · get_code("0bf2c9084103deab")
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 (2, 3, 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

torch.manual_seed(0)

# Create a small flow tensor with shape (batch=2, height=3, width=4, channels=2)
# This represents optical flow vectors at each spatial location
flow = torch.randn(2, 3, 4, 2)

# Test both L1 and L2 normalization
is_l1_true = True
is_l1_false = False

ARGS = {
    "flow": flow,
    "is_l1": is_l1_true
}
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 3, dtype family float, shape (2, 3, 4) — shape (2, 3, 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
flow_read Ran
ran on a synthesized input
Davidyao99/uni4d/dataset_prepare/sintel_io.py
code served (permissive licence) · get_code("a976c9053fc1681f")
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 3, 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 tempfile
import os

# Create a temporary optical flow file in the correct binary format
def create_test_flow_file():
    # Create a temporary file
    fd, filepath = tempfile.mkstemp(suffix='.flo')
    os.close(fd)
    
    # Write flow data in the correct format
    with open(filepath, 'wb') as f:
        TAG_FLOAT = 202021.25
        width = 4
        height = 3
        
        # Write tag
        np.array([TAG_FLOAT], dtype=np.float32).tofile(f)
        # Write width and height
        np.array([width], dtype=np.int32).tofile(f)
        np.array([height], dtype=np.int32).tofile(f)
        
        # Write flow data (U and V components interleaved)
        # Create random flow values
        flow_data = np.random.randn(height, width * 2).astype(np.float32)
        flow_data.tofile(f)
    
    return filepath

# Create the test file
test_flow_file = create_test_flow_file()

ARGS = {
    'filename': test_flow_file
}
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 tuple, ndim 3, 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
get_gt Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/eval_pose.py
code served (permissive licence) · get_code("af61a94065b60b27")
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
import tempfile
import os

# Create a temporary directory to simulate the video_path structure
temp_dir = tempfile.mkdtemp()

# Create a c2w.npy file with ground truth camera poses
# Shape: (num_frames, 4, 4) for camera-to-world transformation matrices
num_frames = 2
c2w_poses = np.zeros((num_frames, 4, 4))

# Create valid 4x4 transformation matrices (rotation + translation)
for i in range(num_frames):
    # 3x3 rotation matrix (identity for simplicity)
    c2w_poses[i, :3, :3] = np.eye(3)
    # 3x1 translation vector
    c2w_poses[i, :3, 3] = np.array([i, i+1, i+2], dtype=np.float32)
    # Bottom row for homogeneous coordinates
    c2w_poses[i, 3, 3] = 1.0

# Save the c2w poses
np.save(os.path.join(temp_dir, 'c2w.npy'), c2w_poses)

ARGS = {
    'video_path': temp_dir
}
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
get_preds Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/eval_pose.py
code served (permissive licence) · get_code("d8e70a5c3026ef98")
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 os
import numpy as np
import tempfile
from scipy.spatial.transform import Rotation as Rot

# Create a temporary directory structure with mock .npz files
temp_dir = tempfile.mkdtemp()
video_path = temp_dir
model_name = "test_model"
experiment_name = "test_experiment"
number_of_frames = 3

# Create the directory structure
images_path = os.path.join(video_path, model_name, experiment_name)
os.makedirs(images_path, exist_ok=True)

# Create mock .npz files with valid rotation matrices and translation vectors
for i in range(number_of_frames):
    # Create a valid rotation matrix using scipy
    rotation = Rot.from_euler('xyz', [10 * i, 20 * i, 30 * i], degrees=True)
    R = rotation.as_matrix()  # 3x3 rotation matrix
    t = np.array([0.1 * i, 0.2 * i, 0.3 * i])  # 3D translation vector
    
    npz_path = os.path.join(images_path, f'{i:04d}.npz')
    np.savez(npz_path, R=R, t=t)

ARGS = {
    "video_path": video_path,
    "model": model_name,
    "experiment_name": experiment_name,
    "number_of_frames": number_of_frames,
}
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
quaternion_to_matrix Ran
ran; our contract draft was wrong, not the code
Davidyao99/uni4d/uni4d/variables.py
pointer only (licence: MIT); the stored copy get_code serves, from Motion-RAG/MoRAG, is pointer only (licence: GPL-3.0) · get_code("000b3a2e5186a974")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from Motion-RAG/MoRAG, and GPL-3.0, as GitHub detects it on that repository, is not in the permissive set Syntology serves inline. 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.

read_trajectory Ran
ran on a synthesized input
Davidyao99/uni4d/dataset_prepare/preprocess_tumd.py
code served (permissive licence) · get_code("339c20f5ac123bcc")
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 sys
import numpy as np
import tempfile
import os

_EPS = 1e-16

def transform44(l):
    """
    Generate a 4x4 homogeneous transformation matrix from a 3D point and unit quaternion.
    
    Input:
    l -- tuple consisting of (stamp,tx,ty,tz,qx,qy,qz,qw) where
         (tx,ty,tz) is the 3D position and (qx,qy,qz,qw) is the unit quaternion.
         
    Output:
    matrix -- 4x4 homogeneous transformation matrix
    """
    t = l[1:4]
    q = np.array(l[4:8], dtype=np.float64, copy=True)
    nq = np.dot(q, q)
    if nq < _EPS:
        return np.array(((1.0, 0.0, 0.0, t[0]), (0.0, 1.0, 0.0, t[1]), (0.0, 0.0, 1.0, t[2]), (0.0, 0.0, 0.0, 1.0)), dtype=np.float64)
    q *= np.sqrt(2.0 / nq)
    q = np.outer(q, q)
    return np.array(((1.0 - q[1, 1] - q[2, 2], q[0, 1] - q[2, 3], q[0, 2] + q[1, 3], t[0]), (q[0, 1] + q[2, 3], 1.0 - q[0, 0] - q[2, 2], q[1, 2] - q[0, 3], t[1]), (q[0, 2] - q[1, 3], q[1, 2] + q[0, 3], 1.0 - q[0, 0] - q[1, 1], t[2]), (0.0, 0.0, 0.0, 1.0)), dtype=np.float64)

def read_trajectory(filename, matrix=False):
    """
    Read a trajectory from a text file. 
    
    Input:
    filename -- file to be read
    matrix -- convert poses to 4x4 matrices
    
    Output:
    dictionary of stamped 3D poses
    """
    file = open(filename)
    data = file.read()
    lines = data.replace(',', ' ').replace('\t', ' ').split('\n')
    list = [[float(v.strip()) for v in line.split(' ') if v.strip() != ''] for line in lines if len(line) > 0 and line[0] != '#']
    list_ok = []
    for i, l in enumerate(list):
        if l[4:8] == [0, 0, 0, 0]:
            continue
        isnan = False
        for v in l:
            if np.isnan(v):
                isnan = True
                break
        if isnan:
            sys.stderr.write("Warning: line %d of file '%s' has NaNs, skipping line\n" % (i, filename))
            continue
        list_ok.append(l)
    if matrix:
        traj = dict([(l[0], transform44(l[0:])) for l in list_ok])
    else:
        traj = dict([(l[0], l[1:8]) for l in list_ok])
    return traj

# Create a temporary trajectory file
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.txt')
temp_filename = temp_file.name

# Write sample trajectory data
# Format: stamp tx ty tz qx qy qz qw
trajectory_data = """# Sample trajectory file
0.0 1.0 2.0 3.0 0.0 0.0 0.7071068 0.7071068
1.0 1.5 2.5 3.5 0.0 0.0 0.7071068 0.7071068
2.0 2.0 3.0 4.0 0.1 0.2 0.7 0.68
"""

temp_file.write(trajectory_data)
temp_file.close()

ARGS = {
    "filename": temp_filename,
    "matrix": False
}
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
signed_expm1 Ran
ran on a synthesized input
Davidyao99/uni4d/uni4d/variables.py
code served (permissive licence) · get_code("68275a37f3c13918")
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

torch.manual_seed(0)

# Create a small tensor with mixed positive and negative values
x = torch.tensor([[-2.0, -0.5, 0.0, 1.5], [0.3, -1.2, 2.0, -0.1]], dtype=torch.float32)

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
fill_depth_nearest Not yet run
unverified (harvested, no recorded run)
Davidyao99/uni4d/uni4d/util.py
code served (permissive licence) · get_code("67bfa3f61f955ce1")
How it ran

no invocation recorded.

hat Not yet run
unverified (harvested, no recorded run)
Davidyao99/uni4d/uni4d/variables.py
code served (permissive licence) · get_code("9ffd7c4d7dfde3e9")
How it ran

no invocation recorded.

transform44 Not yet run
unverified (harvested, no recorded run)
Davidyao99/uni4d/dataset_prepare/preprocess_tumd.py
code served (permissive licence) · get_code("b63ff70118c24067")
How it ran

no invocation recorded.

Also present in other papers' code

Of 18 samples lifted from this paper's linked repositories, 18 carry a function identity and 0 do not. Of the 18 distinct functions with an identity, 2 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 0 later) and 16 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
quaternion_to_matrix 6 other papers
6 dated earlier · 1 only as an assembly brick
2203.04810 (2022-03)
Benchmarking Graphormer on Large-Scale Molecular Modeling Datasets
2209.07589 (2022-09)
PIZZA: A Powerful Image-only Zero-Shot Zero-CAD Approach to 6 DoF Tracking
2210.01776 (2022-10)
DiffDock: Diffusion Steps, Twists, and Turns for Molecular Docking
and 3 more not named here
depth_read 1 other paper
1 dated earlier
2409.02095 (2024-09)
DepthCrafter: Generating Consistent Long Depth Sequences for Open-world Videos

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

Input Video t Input Video Output 4D Scene Models Output 4D Scene Models Figure 1. Given a casually captured video, Uni4D harnesses pretrained visual foundation models and multi-stage optimization to jointly estimate camera poses, dynamic geometry, and dense 3D motion. The resulting camera poses and geometry are accurate, consistent, and coherent both temporally and spatially.

For agents

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

get_harvested_code_for_paper("2503.21761")
get_code_for_paper("2503.21761")
have("2503.21761")

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

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

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

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

Connect an agent — have() is free.