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.6

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.6
File Size Uploaded
transform_tree-0.0.6.tar.gz 626.7 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for transform-tree 0.0.6
File
transform_tree-0.0.6-cp314-cp314t-win_amd64.whl CPython 3.14 CPython 3.14 free-threading Windows x86-64 Details
transform_tree-0.0.6-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.6-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.6-cp314-cp314t-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64 Details
transform_tree-0.0.6-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details
transform_tree-0.0.6-cp39-abi3-musllinux_1_2_x86_64.whl CPython 3.9 abi3 Linux musl 1.2+ x86-64 Details
transform_tree-0.0.6-cp39-abi3-musllinux_1_2_aarch64.whl CPython 3.9 abi3 Linux musl 1.2+ ARM64 Details
transform_tree-0.0.6-cp39-abi3-manylinux_2_28_x86_64.whl CPython 3.9 abi3 Linux glibc 2.28+ x86-64 Details
transform_tree-0.0.6-cp39-abi3-manylinux_2_28_aarch64.whl CPython 3.9 abi3 Linux glibc 2.28+ ARM64 Details
transform_tree-0.0.6-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
transform_tree-0.0.6-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.6.tar.gz

Download URL transform_tree-0.0.6.tar.gz
Size 626.7 kB
Tags Source
SHA-256 checksum
How to use checksums
43196a204c836e907ec51129bef371d43fea57d886fa8e06b8d4995e1b3bf1e4
BLAKE2b-256 checksum
How to use checksums
e9a595949b1dd379d942377d4d127796039f9ea55ce7603d4f2db0e98e0073ae
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp314-cp314t-win_amd64.whl
Size 574.7 kB
Tags CPython 3.14 CPython 3.14 free-threading Windows x86-64
SHA-256 checksum
How to use checksums
cd4f27c4e0301eaa4ef2df91fc471d7cb9c1cdebd542b101484277999319ec4f
BLAKE2b-256 checksum
How to use checksums
f478d19c99f7f8ffd94a6c02192787e3ad4fbff72727e39d0fd5f3cdd4331dbf
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp314-cp314t-manylinux_2_28_x86_64.whl
Size 724.3 kB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
7f3320465a9dc933c45635f2f05158c190013576f4bd1b2f13d0d0a7803980e7
BLAKE2b-256 checksum
How to use checksums
89c37b1150af64af92d9a57303d67aab2ed9df477075f6c20d1711f4c726d8ae
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp314-cp314t-manylinux_2_28_aarch64.whl
Size 670.8 kB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
6c349c66c27f2aadd8374b6e15d9baca424000fa309092e97effd5ea8afba64c
BLAKE2b-256 checksum
How to use checksums
c398d18cd274225094bbb63653cad0790b7b64952ac8654a7a1e2be7202d24e4
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp314-cp314t-macosx_11_0_arm64.whl
Size 578.2 kB
Tags CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
443c14fac2d8faa5c97b54778bb1e425bc55f1461f87ba01117ab15d4f76249a
BLAKE2b-256 checksum
How to use checksums
f19b14e089677fbf8a060b15e4f61cbca669f28f82b6548162bd87b17ead3c53
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-win_amd64.whl
Size 590.4 kB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
f8a374e3201ccaf35048feba403e0398f3c21ad2ff07e9cc0da21e25cd265c29
BLAKE2b-256 checksum
How to use checksums
4206d8c6db75fda2088257ea187ebca2dfbcccfa31b31f7468d07aefc45b69a0
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-musllinux_1_2_x86_64.whl
Size 948.2 kB
Tags CPython 3.9 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
0eb1bf190c70b7f890d1f668bbbf748e5deccdae64330fa8c03b2c30ffd4d1eb
BLAKE2b-256 checksum
How to use checksums
6fa842918af67a570114c6dffa587908db24e13860797a59b44fc9c39d738aa5
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-musllinux_1_2_aarch64.whl
Size 857.4 kB
Tags CPython 3.9 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
1b7db839cf56122a0cecc308237ac0f795a5f41f87909ba119f2f67b149b7cda
BLAKE2b-256 checksum
How to use checksums
adb2b7faf1c305e2342f04700345b39a335002ed23740747f767c9c13ca18f5b
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-manylinux_2_28_x86_64.whl
Size 734.4 kB
Tags CPython 3.9 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
b1514d9a29a8e2436c2ec9ba9c48de5accfc9cb34927b479f931537c4cb2f511
BLAKE2b-256 checksum
How to use checksums
dd2b9bbb004dd2fc26e8bc63fdf10e26ecfbb418f29f4267ea6323dee547a11b
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-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
dd3215518e3a4e3b08379f37f7b6d8b6a64ab37602fdfde287bb1fa01c85d1c4
BLAKE2b-256 checksum
How to use checksums
f328cd16b977790cb9a76cc284ba5b6e4af13ad8d74bf873fbfb072d9b6a54ab
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-macosx_11_0_arm64.whl
Size 589.5 kB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
81e002eacf06a47680fc8b3dd5925e186640a5c0e41c3ecbce796ac4001cb346
BLAKE2b-256 checksum
How to use checksums
fc0d7143e2a571b24fb57e9f26b1197a2bec72c46cfb7a41eb07f7c621bee18e
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 Sep 20, 2026.

Transparency log

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

Download URL transform_tree-0.0.6-cp39-abi3-macosx_10_12_x86_64.whl
Size 633.1 kB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
2c14290e6683c409394f1b6c6211e5d23926a7c1cd20cfbefa14234b338f65f4
BLAKE2b-256 checksum
How to use checksums
c8da1926520107680ee519c156fbc80685085027013e678971515e8893e2ac85
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 Sep 20, 2026.

Transparency log

Release history Release notifications | RSS feed

0.0.7

12 release files

This release

0.0.6 This release

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