Skip to main content

tf_tree

crates.io docs.rs PyPI CI Licence

A transform tree: it stores time-stamped poses between named frames and answers "where was frame A relative to frame B at time t?". Use it in a control loop, across processes on one host, or in a dataloader with no robot attached.

It is faster than ROS tf2 (below) but is not tf2: no ROS dependency and no drop-in tf2_ros::Buffer, only a one-way /tf ingest bridge (0008). Linux first: shared memory and frozen .tft files are Linux-only (shm feature); the in-process engine is portable.

0.0.x promises nothing between releases. Pin exactly (CHANGELOG.md).

Install

  • Rust: cargo add tf_tree
  • Python: pip install transform_tree, then import tf_tree
  • CLI (tf_tree, alias tft): a binary from the latest release, or cargo install --path crates/tf_tree_cli --features shm
  • C ABI, C++ header, ROS 2 bridge: just c-abi-check, just cpp-check, just ros-build

Quickstart

Python, from scratch (just quickstart runs this). Stamps are integer nanoseconds; a pose is [qw, qx, qy, qz, x, y, z].

import tf_tree

tree = tf_tree.build([("map", "base"), ("base", "cam")])
tf_tree.push(tree, "base", "map", 1_000, [1, 0, 0, 0, 1.0, 2.0, 3.0])
tf_tree.push(tree, "base", "map", 2_000, [1, 0, 0, 0, 3.0, 4.0, 5.0])

plan = tree.plan("map", "base")   # compile the route once, reuse it
print(plan.at(1_500)[:3, 3])      # -> [2. 3. 4.]

Rust:

use tf_tree::{Capacity, EdgeCfg, Iso3, Quat, Stamp, TreeBuilder, Vec3};

let tree = TreeBuilder::new()
    .static_edge("base_link", "lidar_top", &Iso3::IDENTITY)   // (parent, child)
    .dynamic_edge("odom", "base_link", EdgeCfg::new(Capacity::history(100.0, 10.0)))
    .build()
    .expect("layout");
let odom = tree.frame("odom").expect("declared");
let base_link = tree.frame("base_link").expect("declared");
let lidar_top = tree.frame("lidar_top").expect("declared");

let w = tree.claim(base_link, odom).expect("unclaimed");   // (child, parent)
let at_x = |x| Iso3::new(Quat::IDENTITY, Vec3::new(x, 0.0, 0.0));
w.push(1_000_000_000, &at_x(0.0)).expect("monotonic");
w.push(1_010_000_000, &at_x(1.0)).expect("monotonic");

let plan = tree.plan(odom, lidar_top).expect("connected");
let g = tree.guard();
let t: Stamp = Stamp::from_nanos(1_005_000_000);
let pose = plan.at(&g, t).expect("in range");
assert!((pose.t.x - 0.5).abs() < 1e-12);

From a recorded bag

MCAP only (for .db3, run ros2 bag convert first):

tft doctor --from-bag drive.mcap                 # what is wrong with this /tf traffic
tft freeze --from-bag drive.mcap -o drive.tft    # index it
tree = tf_tree.open_file("drive.tft")   # an mmap; open per worker, after fork/spawn
poses = tree.plan("base_link", "lidar_top").at(stamps_ns, layout="quat_twist")  # (N, 13)

Against tf2

In-process, one thread, same interpolation, tf2 called natively; 4-core EPYC-Milan, not core-pinned. Both agree to 7e-15 on 50,000 recorded queries.

tf_tree tf2
Lookup, depth 3 94 ns 253 ns 2.7×
Lookup, depth 15 1193 ns 7337 ns 6.2×
Publish 9.4 ns 114 ns 12.1×

Without LTO the lookup gap is 1.8×; through the C ABI, 1.5×. Method: tf2.md; sources: EVIDENCE.md.

Not for

Need Why See
Drop-in tf2_ros::Buffer gated, not scheduled PHASE7.md
Covariance, multi-parent frames, loop closure cut 0009
Transforms across hosts not started PROJECT.md §4
Shared memory or .tft off Linux not implemented SUPPORT.md
A viewer, point-cloud deskewing deliberately absent PHASE5.md §8

Status

Phase Status
1 Engine: arena, seqlock buffers, plans, SE(3) math Implemented
2 Shared memory across processes Implemented, with gaps
3 Python bindings Implemented
4 C ABI, C++ wrapper, ROS 2 ingest, derivatives Implemented, with gaps
5 Frozen .tft, bag ingestion, diagnostics, tf_tree top Mostly implemented
6–8 Continuous time, tf2 shim, multi-host Not started

The §0.0 tables in PHASE2, PHASE4 and PHASE5 win over this one.

Shared memory is not a sandbox

Processes sharing an arena trust each other: a read-write participant can corrupt it (PHASE2.md §3.10; SECURITY.md). A read-only participant (the default for readers) cannot, and a crashed or hung one cannot wedge the others.

fork() is the sharp edge: a child's inherited handles report ChildDetached. Python's multiprocessing forks by default on Linux, so open the arena inside the worker or use spawn. A frozen .tft survives a fork.

Layout

crates/: tf_tree_math, tf_tree_arena, tf_tree_core, tf_tree (facade), tf_tree_ipc, tf_tree_c, tf_tree_bridge, tf_tree_ingest, tf_tree_py, tf_tree_bench, tf_tree_tf2_sys, tf_tree_cli. ros/ holds the ROS 2 packages. tf_tree_py, tf_tree_tf2_sys and ros/ sit outside the cargo workspace and have their own just recipes. Five crates publish: tf_tree, tf_tree_core, tf_tree_math, tf_tree_arena, tf_tree_ipc. MSRV 1.87.

Docs: docs/README.md · CONTRIBUTING.md · SUPPORT.md · SECURITY.md · CODE_OF_CONDUCT.md

Licence

Dual MIT / Apache-2.0, at your option. See NOTICE.

Metadata

Release files for transform-tree 0.0.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for transform-tree 0.0.7
File Size Uploaded
transform_tree-0.0.7.tar.gz 630.3 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for transform-tree 0.0.7
File
transform_tree-0.0.7-cp314-cp314t-win_amd64.whl CPython 3.14 CPython 3.14 free-threading Windows x86-64 Details
transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ x86-64 Details
transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_aarch64.whl CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ ARM64 Details
transform_tree-0.0.7-cp314-cp314t-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64 Details
transform_tree-0.0.7-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details
transform_tree-0.0.7-cp39-abi3-musllinux_1_2_x86_64.whl CPython 3.9 abi3 Linux musl 1.2+ x86-64 Details
transform_tree-0.0.7-cp39-abi3-musllinux_1_2_aarch64.whl CPython 3.9 abi3 Linux musl 1.2+ ARM64 Details
transform_tree-0.0.7-cp39-abi3-manylinux_2_28_x86_64.whl CPython 3.9 abi3 Linux glibc 2.28+ x86-64 Details
transform_tree-0.0.7-cp39-abi3-manylinux_2_28_aarch64.whl CPython 3.9 abi3 Linux glibc 2.28+ ARM64 Details
transform_tree-0.0.7-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
transform_tree-0.0.7-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details

Total release size: 8.2 MB

Release files / transform_tree-0.0.7.tar.gz

Download URL transform_tree-0.0.7.tar.gz
Size 630.3 kB
Tags Source
SHA-256 checksum
How to use checksums
d96a101d1447555f2f73bb2f14e4e756209a04844084f77ac90d13cf41f49c50
BLAKE2b-256 checksum
How to use checksums
c443de6650a8367fce6425099a8a87fbec93ba0f97c87dcec618b658b1d36473
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp314-cp314t-win_amd64.whl

Download URL transform_tree-0.0.7-cp314-cp314t-win_amd64.whl
Size 581.2 kB
Tags CPython 3.14 CPython 3.14 free-threading Windows x86-64
SHA-256 checksum
How to use checksums
d32b6b9c0401906eab99e07ac04bbdb0ecb575c08d14cbbd120ce3c261236c15
BLAKE2b-256 checksum
How to use checksums
21d41ef48e9f4efbc90be99091eaa0b1b170d90b0072077ec41a996b804efbff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_x86_64.whl

Download URL transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_x86_64.whl
Size 726.8 kB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
a2594886ed523cdefe16441517ad75b50bc99080b98ed32a037540f9dd8f4399
BLAKE2b-256 checksum
How to use checksums
c16b9f1de9a8e75c9834dd58787d6d8469bcde425c5758f791fffa6fc3fbb458
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_aarch64.whl

Download URL transform_tree-0.0.7-cp314-cp314t-manylinux_2_28_aarch64.whl
Size 671.1 kB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
76812b23b2aeb434da41180d4805422e470061b128ab3dd37463d7cbb54fba18
BLAKE2b-256 checksum
How to use checksums
c909592647b24f6a8a4ef318e757a5d4c679fe81948f3fffaa11999309e648a6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp314-cp314t-macosx_11_0_arm64.whl

Download URL transform_tree-0.0.7-cp314-cp314t-macosx_11_0_arm64.whl
Size 580.0 kB
Tags CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
7343ccab50dbb2467111bd7ffb7846ba170f615c16973f8fc06496fee57ee773
BLAKE2b-256 checksum
How to use checksums
5d8f698f428ee019351878657986ea1651e1e6380d3004e97ffbc270b70f49a6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-win_amd64.whl

Download URL transform_tree-0.0.7-cp39-abi3-win_amd64.whl
Size 595.5 kB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
198ccf59b6255227be0ee8ff71c083deda3e6a977ce1de93c44b7476f9602dde
BLAKE2b-256 checksum
How to use checksums
a4ab45cc8b8a9e10e9f82d67300081389b2a123da8f083c6e18cc857e9732dbf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-musllinux_1_2_x86_64.whl

Download URL transform_tree-0.0.7-cp39-abi3-musllinux_1_2_x86_64.whl
Size 949.8 kB
Tags CPython 3.9 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
efc7670f5df32b907455990feca3a66232969fcf8a0b95fc66e6f58302a9e3ed
BLAKE2b-256 checksum
How to use checksums
5721b4337460db7b550f79246b52e57e4fea33c13365c16f61f875b55e2091d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-musllinux_1_2_aarch64.whl

Download URL transform_tree-0.0.7-cp39-abi3-musllinux_1_2_aarch64.whl
Size 857.9 kB
Tags CPython 3.9 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
075e38fab648c4470981c9625acc08fd246e2c8f411012d56bdd8df6cd87164a
BLAKE2b-256 checksum
How to use checksums
6e2bfe05a5201400f91b45992d1b81a044d51c24d7701eb6689f51c9c515f9a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-manylinux_2_28_x86_64.whl

Download URL transform_tree-0.0.7-cp39-abi3-manylinux_2_28_x86_64.whl
Size 735.9 kB
Tags CPython 3.9 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
56a36bf96c9c2a70edc15865a7024c30007885941ac82df732d1768c71f519ff
BLAKE2b-256 checksum
How to use checksums
c520dc0cb34dec2d10f9b678809d68bbf50d803969e7bb5aede2722388acf77d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-manylinux_2_28_aarch64.whl

Download URL transform_tree-0.0.7-cp39-abi3-manylinux_2_28_aarch64.whl
Size 680.1 kB
Tags CPython 3.9 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
d32ee34aec49b3b824ef4a3df397de19188170169a7d8bb4ae5548dc714ab2d9
BLAKE2b-256 checksum
How to use checksums
5b752e1ed452739d6e04969648ab355d132159c2f9a8a571ddc46bab650890e5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-macosx_11_0_arm64.whl

Download URL transform_tree-0.0.7-cp39-abi3-macosx_11_0_arm64.whl
Size 590.3 kB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
fb5501beef62acc335d9897360137ec2fe6196cdc0c2d535aa1491750f5b4335
BLAKE2b-256 checksum
How to use checksums
f274c1cf07ebd1e90822839f1adb4f739ee81d4d0089f00f45a35b751be5defc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / transform_tree-0.0.7-cp39-abi3-macosx_10_12_x86_64.whl

Download URL transform_tree-0.0.7-cp39-abi3-macosx_10_12_x86_64.whl
Size 639.5 kB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
5c6090e17cce36cb90a534852766249049c00e3f030037a0adf68405a30221e5
BLAKE2b-256 checksum
How to use checksums
d9f09d844c9b984d9729c2f7938a133bcf1e328c37ce0404b0fa103ab485775f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.0.7 This release

12 release files

0.0.6

12 release files

0.0.5

12 release files

0.0.4

12 release files

0.0.3

12 release files

0.0.2

11 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page