Skip to main content

High-fidelity OpenTelemetry (OTel) bridge for MuJoCo. Industrial-grade observability for agentic robotics.

Project description

utrompulse (v0.2.0)

A high-performance, asynchronous telemetry framework for MuJoCo simulations. utrompulse decouples physics computation from observability I/O, providing semantically labeled telemetry via OpenTelemetry (OTLP) and local binary logging (MCAP).

Key Features

  • Zero-Blocking Architecture: High-frequency state extraction (<50μs) to preserve physics determinism.
  • Semantic Instrumentation: Automatically maps raw mjData indices to human-readable XML joint and actuator names.
  • Multiplexed Transports: Simultaneously stream to live OTLP backends (Jaeger) and local disk (MCAP/Foxglove).
  • Real-Time Safety: Implements a Head-Dropping Circular Buffer to ensure telemetry freshness without memory overflows.

Architecture

utrompulse utilizes an air-gapped dispatcher model to isolate the simulation thread:

  1. ModelInstrument: Inspects the mjModel at runtime to create a semantic name-to-index map.
  2. ZeroBlockingHook: Captures state snapshots and pushes them into a thread-safe circular queue.
  3. PulseExporter: A background daemon that broadcasts snapshots to all registered BaseTransport backends.

Installation

Ensure you have Python 3.11+ and uv installed.

git clone [https://github.com/mustafa-5493/UtromPulse.git](https://github.com/mustafa-5493/UtromPulse.git)
cd UtromPulse
uv sync

Usage

Modern usage involving semantic mapping and multiple transport outputs:

import mujoco
from utrompulse.bridge.mujoco_hook import ZeroBlockingHook
from utrompulse.bridge.instrumentation import ModelInstrument
from utrompulse.telemetry.otel_exporter import PulseExporter
from utrompulse.transports.otlp import OTLPTransport
from utrompulse.transports.mcap import MCAPTransport

# 1. Load Model
model = mujoco.MjModel.from_xml_path("robot.xml")
data = mujoco.MjData(model)

# 2. Initialize Instrumentation & Hook
instrument = ModelInstrument(model)
hook = ZeroBlockingHook(max_queue_size=5000)

# 3. Configure Transports (Live + Local)
transports = [
    OTLPTransport(endpoint="http://localhost:4317"),
    MCAPTransport(output_path="recording.mcap")
]

# 4. Start Exporter
exporter = PulseExporter(telemetry_queue=hook.telemetry_queue, transports=transports)
exporter.start()

try:
    while True:
        mujoco.mj_step(model, data)
        # Capture state with semantic labels
        hook.capture_state(step=data.time, data=data, instrument=instrument)
finally:
    exporter.stop()

Observability Backends

Live Tracing (Jaeger)

Run Jaeger with OTLP support:

docker run -d --name jaeger -p 16686:16686 -p 4317:4317 jaegertracing/all-in-one:latest

Access the UI at http://localhost:16686 to view semantically labeled spans (e.g., joint.left_hip_pitch).

Offline Analysis (Foxglove)

The MCAPTransport generates a .mcap file. Drag and drop this file into Foxglove Studio to visualize high-frequency joint data, control signals, and system jitter offline.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

utrompulse-0.2.0.tar.gz (70.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

utrompulse-0.2.0-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file utrompulse-0.2.0.tar.gz.

File metadata

  • Download URL: utrompulse-0.2.0.tar.gz
  • Upload date:
  • Size: 70.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for utrompulse-0.2.0.tar.gz
Algorithm Hash digest
SHA256 3deda3338d3e9ef69837e1830b1e9d1a538d73c6a327cf16c47208ef042c2917
MD5 706b95096313e2547f2f328a95a89a3c
BLAKE2b-256 978058a2f17f69011be8ae26f2a4b1f3d7d873bbb042b6fceab956af8d86dfca

See more details on using hashes here.

File details

Details for the file utrompulse-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: utrompulse-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for utrompulse-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5c9570cd2ca54fd11dfe83e708a79d46781a2e7994647525bcc13a75cc361bcb
MD5 f0a7186b5b307b14408fd00d88a596d0
BLAKE2b-256 387c7de14372782ca36c82b90dd78eec04189696c8c23fa0fc4b1687fd96c595

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page