Skip to main content

The Rerun Logging SDK

Project description

The Rerun Python SDK

Use the Rerun SDK to record data like images, tensors, point clouds, and text. Data is streamed to the Rerun Viewer for live visualization or to file for later use.

Rerun Viewer

Install

pip3 install rerun-sdk

ℹ️ Note: The Python module is called rerun, while the package published on PyPI is rerun-sdk.

For other SDK languages see Installing Rerun.

Example

import rerun as rr
import numpy as np

rr.init("rerun_example_app", spawn=True)

positions = np.vstack([xyz.ravel() for xyz in np.mgrid[3 * [slice(-5, 5, 10j)]]]).T
colors = np.vstack([rgb.ravel() for rgb in np.mgrid[3 * [slice(0, 255, 10j)]]]).astype(np.uint8).T

rr.log("points3d", rr.Points3D(positions, colors=colors))

Resources

Logging and viewing in different processes

You can run the Viewer and logger in different processes.

In one terminal, start up a Viewer with a server that the SDK can connect to:

python3 -m rerun

In a second terminal, run the example with the --connect option:

python3 examples/python/plots/plots.py --connect

Note that SDK and Viewer can run on different machines!

Building Rerun from source

We use the pixi for managing dev-tool versioning, download and task running. See here for installation instructions.

pixi run py-build --release

To build SDK & Viewer for Python (or pixi run py-build for a debug build) and install it in the Pixi environment.

You can then run examples from the repository, either by making the Pixi shell active with pixi shell and then running Python or by using pixi run, e.g. pixi run python examples/python/minimal/minimal.py.

Respectively, to build a wheel instead for manual install use:

pixi run py-wheel --release

Refer to BUILD.md for details on the various different build options of the Rerun Viewer and SDKs for all target languages.

Installing a pre-release

Prebuilt dev wheels from head of main are available at https://github.com/rerun-io/rerun/releases/tag/prerelease.

While we try to keep the main branch usable at all times, it may be unstable occasionally. Use at your own risk.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

rerun_sdk-0.16.1-cp38-abi3-win_amd64.whl (28.0 MB view details)

Uploaded CPython 3.8+Windows x86-64

rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_x86_64.whl (37.0 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.31+ x86-64

rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_aarch64.whl (36.8 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.31+ ARM64

rerun_sdk-0.16.1-cp38-abi3-macosx_11_0_arm64.whl (30.5 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

rerun_sdk-0.16.1-cp38-abi3-macosx_10_12_x86_64.whl (31.2 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file rerun_sdk-0.16.1-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for rerun_sdk-0.16.1-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 be88799c8afdf68eafa99e64e2e4f0a484e187e017a180219abbe6bb988acd4e
MD5 41e833e58478da535ee37f848cbb6ff5
BLAKE2b-256 0869be7810460a7b739034c951ab7c2d89f5648cf55d61e468fb3cb2260f5bb8

See more details on using hashes here.

File details

Details for the file rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_x86_64.whl.

File metadata

File hashes

Hashes for rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 37b7b47948471873e84f224b16f417a94a91c7cbd6c72c68281eeff1ba414b8f
MD5 67a3331e547e5c4186f1c7e830039e61
BLAKE2b-256 34cd2165450a91cdaac5a9a09862e81f2f44a61fc902751954b3f6ddc113c729

See more details on using hashes here.

File details

Details for the file rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_aarch64.whl.

File metadata

File hashes

Hashes for rerun_sdk-0.16.1-cp38-abi3-manylinux_2_31_aarch64.whl
Algorithm Hash digest
SHA256 4d6436752d57e8b8038489a0e7e37f0c760b088e96db5fb81667d3a376d63fea
MD5 354733954c4b4b12506d80b24259cbb1
BLAKE2b-256 a2325c220f61c72215e686bffcce1a7273e56a05109ea42d425dacbd9997300e

See more details on using hashes here.

File details

Details for the file rerun_sdk-0.16.1-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rerun_sdk-0.16.1-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c9a76eab7eb5559276737dad655200e9350df0837158dbc5a896970ab4201454
MD5 979413e131b1e8776dc9724fe8c680f8
BLAKE2b-256 2ab31fdad82b064d8bab5f06f5baa33a7e4db475514c14f876d72182404df0ff

See more details on using hashes here.

File details

Details for the file rerun_sdk-0.16.1-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for rerun_sdk-0.16.1-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 170c6976634008611753e10dfef8cdc395ce8180e634c169e7c61cef2f89a277
MD5 5118f5691f5fbfa6f0217b93753ce3c1
BLAKE2b-256 62974f61141d7dcadc30f5e4f6279823068b3a96e42acb3245544dd4e156c8cc

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