Skip to content

Archetypes

rerun.blueprint.archetypes

class Background

Bases: BackgroundExt, Archetype

Archetype: Configuration for the background of a view.

def __init__(color_or_kind=None, *, color=None, kind=None)

Create a new instance of the Background archetype.

PARAMETER DESCRIPTION
color_or_kind

Either a color for solid background color or kind of the background (see BackgroundKind). If set, color and kind must not be set.

TYPE: Rgba32Like | BackgroundKindLike | None DEFAULT: None

kind

The type of the background. Defaults to BackgroundKind.GradientDark.

TYPE: BackgroundKindLike | None DEFAULT: None

color

Color used for BackgroundKind.SolidColor.

Defaults to White.

TYPE: Rgba32Like | None DEFAULT: None

class ContainerBlueprint

Bases: Archetype

Archetype: The description of a container.

def __init__(container_kind, *, display_name=None, contents=None, col_shares=None, row_shares=None, active_tab=None, visible=None, grid_columns=None)

Create a new instance of the ContainerBlueprint archetype.

PARAMETER DESCRIPTION
container_kind

The class of the view.

TYPE: ContainerKindLike

display_name

The name of the container.

TYPE: Utf8Like | None DEFAULT: None

contents

ContainerIds or ViewIds that are children of this container.

TYPE: EntityPathArrayLike | None DEFAULT: None

col_shares

The layout shares of each column in the container.

For components.ContainerKind.Horizontal containers, the length of this list should always match the number of contents.

Ignored for components.ContainerKind.Vertical containers.

TYPE: Float32ArrayLike | None DEFAULT: None

row_shares

The layout shares of each row of the container.

For components.ContainerKind.Vertical containers, the length of this list should always match the number of contents.

Ignored for components.ContainerKind.Horizontal containers.

TYPE: Float32ArrayLike | None DEFAULT: None

active_tab

Which tab is active.

Only applies to Tabs containers.

TYPE: EntityPathLike | None DEFAULT: None

visible

Whether this container is visible.

Defaults to true if not specified.

TYPE: BoolLike | None DEFAULT: None

grid_columns

How many columns this grid should have.

If unset, the grid layout will be auto.

Ignored for components.ContainerKind.Horizontal/components.ContainerKind.Vertical containers.

TYPE: UInt32Like | None DEFAULT: None

class DataframeQuery

Bases: DataframeQueryExt, Archetype

Archetype: The query for the dataframe view.

def __init__(*, timeline=None, filter_by_range=None, filter_is_not_null=None, apply_latest_at=False, select=None)

Create a new instance of the DataframeQuery archetype.

PARAMETER DESCRIPTION
timeline

The timeline for this query.

TYPE: Utf8Like | None DEFAULT: None

filter_by_range

If set, a range filter is applied.

TYPE: tuple[TimeInt, TimeInt] | FilterByRangeLike | None DEFAULT: None

filter_is_not_null

If provided, the dataframe will only contain rows corresponding to timestamps at which an event was logged for the provided column.

TYPE: ComponentColumnSelectorLike | None DEFAULT: None

apply_latest_at

Should empty cells be filled with latest-at queries?

TYPE: bool DEFAULT: False

select

Selected columns. If unset, all columns are selected.

TYPE: list[ComponentColumnSelectorLike | Utf8Like | str] | None DEFAULT: None

class ForceCenter

Bases: Archetype

Archetype: Tries to move the center of mass of the graph to the origin.

def __init__(*, enabled=None, strength=None)

Create a new instance of the ForceCenter archetype.

PARAMETER DESCRIPTION
enabled

Whether the center force is enabled.

The center force tries to move the center of mass of the graph towards the origin.

TYPE: BoolLike | None DEFAULT: None

strength

The strength of the force.

TYPE: Float64Like | None DEFAULT: None

class ForceCollisionRadius

Bases: Archetype

Archetype: Resolves collisions between the bounding circles, according to the radius of the nodes.

def __init__(*, enabled=None, strength=None, iterations=None)

Create a new instance of the ForceCollisionRadius archetype.

PARAMETER DESCRIPTION
enabled

Whether the collision force is enabled.

The collision force resolves collisions between nodes based on the bounding circle defined by their radius.

TYPE: BoolLike | None DEFAULT: None

strength

The strength of the force.

TYPE: Float64Like | None DEFAULT: None

iterations

Specifies how often this force should be applied per iteration.

Increasing this parameter can lead to better results at the cost of longer computation time.

TYPE: UInt64Like | None DEFAULT: None

Bases: Archetype

Archetype: Aims to achieve a target distance between two nodes that are connected by an edge.

def __init__(*, enabled=None, distance=None, iterations=None)

Create a new instance of the ForceLink archetype.

PARAMETER DESCRIPTION
enabled

Whether the link force is enabled.

The link force aims to achieve a target distance between two nodes that are connected by one ore more edges.

TYPE: BoolLike | None DEFAULT: None

distance

The target distance between two nodes.

TYPE: Float64Like | None DEFAULT: None

iterations

Specifies how often this force should be applied per iteration.

Increasing this parameter can lead to better results at the cost of longer computation time.

TYPE: UInt64Like | None DEFAULT: None

class ForceManyBody

Bases: Archetype

Archetype: A force between each pair of nodes that ressembles an electrical charge.

If strength is smaller than 0, it pushes nodes apart, if it is larger than 0 it pulls them together.

def __init__(*, enabled=None, strength=None)

Create a new instance of the ForceManyBody archetype.

PARAMETER DESCRIPTION
enabled

Whether the many body force is enabled.

The many body force is applied on each pair of nodes in a way that ressembles an electrical charge. If the strength is smaller than 0, it pushes nodes apart; if it is larger than 0, it pulls them together.

TYPE: BoolLike | None DEFAULT: None

strength

The strength of the force.

If strength is smaller than 0, it pushes nodes apart, if it is larger than 0 it pulls them together.

TYPE: Float64Like | None DEFAULT: None

class ForcePosition

Bases: Archetype

Archetype: Similar to gravity, this force pulls nodes towards a specific position.

def __init__(*, enabled=None, strength=None, position=None)

Create a new instance of the ForcePosition archetype.

PARAMETER DESCRIPTION
enabled

Whether the position force is enabled.

The position force pulls nodes towards a specific position, similar to gravity.

TYPE: BoolLike | None DEFAULT: None

strength

The strength of the force.

TYPE: Float64Like | None DEFAULT: None

position

The position where the nodes should be pulled towards.

TYPE: Vec2DLike | None DEFAULT: None

class LineGrid3D

Bases: Archetype

Archetype: Configuration for the 3D line grid.

def __init__(*, visible=None, spacing=None, plane=None, stroke_width=None, color=None)

Create a new instance of the LineGrid3D archetype.

PARAMETER DESCRIPTION
visible

Whether the grid is visible.

Defaults to true.

TYPE: BoolLike | None DEFAULT: None

spacing

Space between grid lines spacing of one line to the next in scene units.

As you zoom out, successively only every tenth line is shown. This controls the closest zoom level.

TYPE: Float32Like | None DEFAULT: None

plane

In what plane the grid is drawn.

Defaults to whatever plane is determined as the plane at zero units up/down as defined by components.ViewCoordinates if present.

TYPE: Plane3DLike | None DEFAULT: None

stroke_width

How thick the lines should be in ui units.

Default is 1.0 ui unit.

TYPE: Float32Like | None DEFAULT: None

color

Color used for the grid.

Transparency via alpha channel is supported. Defaults to a slightly transparent light gray.

TYPE: Rgba32Like | None DEFAULT: None

class MapBackground

Bases: Archetype

Archetype: Configuration for the background map of the map view.

def __init__(provider)

Create a new instance of the MapBackground archetype.

PARAMETER DESCRIPTION
provider

Map provider and style to use.

Note: Requires a Mapbox API key in the RERUN_MAPBOX_ACCESS_TOKEN environment variable.

TYPE: MapProviderLike

class MapZoom

Bases: Archetype

Archetype: Configuration of the map view zoom level.

def __init__(zoom)

Create a new instance of the MapZoom archetype.

PARAMETER DESCRIPTION
zoom

Zoom level for the map.

Zoom level follow the OpenStreetMap definition.

TYPE: Float64Like

class NearClipPlane

Bases: Archetype

Archetype: Controls the distance to the near clip plane in 3D scene units.

def __init__(near_clip_plane)

Create a new instance of the NearClipPlane archetype.

PARAMETER DESCRIPTION
near_clip_plane

Controls the distance to the near clip plane in 3D scene units.

Content closer than this distance will not be visible.

TYPE: Float32Like

class PanelBlueprint

Bases: Archetype

Archetype: Shared state for the 3 collapsible panels.

def __init__(*, state=None)

Create a new instance of the PanelBlueprint archetype.

PARAMETER DESCRIPTION
state

Current state of the panels.

TYPE: PanelStateLike | None DEFAULT: None

class PlotLegend

Bases: PlotLegendExt, Archetype

Archetype: Configuration for the legend of a plot.

def __init__(corner=None, *, visible=None)

Create a new instance of the PlotLegend archetype.

PARAMETER DESCRIPTION
corner

To what corner the legend is aligned.

Defaults to the right bottom corner.

TYPE: Corner2DLike | None DEFAULT: None

visible

Whether the legend is shown at all.

True by default.

TYPE: BoolLike | None DEFAULT: None

class ScalarAxis

Bases: Archetype

Archetype: Configuration for the scalar axis of a plot.

def __init__(*, range=None, zoom_lock=None)

Create a new instance of the ScalarAxis archetype.

PARAMETER DESCRIPTION
range

The range of the axis.

If unset, the range well be automatically determined based on the queried data.

TYPE: Range1DLike | None DEFAULT: None

zoom_lock

If enabled, the Y axis range will remain locked to the specified range when zooming.

TYPE: BoolLike | None DEFAULT: None

class TensorScalarMapping

Bases: Archetype

Archetype: Configures how tensor scalars are mapped to color.

def __init__(*, mag_filter=None, colormap=None, gamma=None)

Create a new instance of the TensorScalarMapping archetype.

PARAMETER DESCRIPTION
mag_filter

Filter used when zooming in on the tensor.

Note that the filter is applied to the scalar values before they are mapped to color.

TYPE: MagnificationFilterLike | None DEFAULT: None

colormap

How scalar values map to colors.

TYPE: ColormapLike | None DEFAULT: None

gamma

Gamma exponent applied to normalized values before mapping to color.

Raises the normalized values to the power of this value before mapping to color. Acts like an inverse brightness. Defaults to 1.0.

The final value for display is set as: colormap( ((value - data_display_range.min) / (data_display_range.max - data_display_range.min)) ** gamma )

TYPE: Float32Like | None DEFAULT: None

class TensorSliceSelection

Bases: Archetype

Archetype: Specifies a 2D slice of a tensor.

def __init__(*, width=None, height=None, indices=None, slider=None)

Create a new instance of the TensorSliceSelection archetype.

PARAMETER DESCRIPTION
width

Which dimension to map to width.

If not specified, the height will be determined automatically based on the name and index of the dimension.

TYPE: TensorDimensionSelectionLike | None DEFAULT: None

height

Which dimension to map to height.

If not specified, the height will be determined automatically based on the name and index of the dimension.

TYPE: TensorDimensionSelectionLike | None DEFAULT: None

indices

Selected indices for all other dimensions.

If any of the here listed dimensions is equal to width or height, it will be ignored.

TYPE: TensorDimensionIndexSelectionArrayLike | None DEFAULT: None

slider

Any dimension listed here will have a slider for the index.

Edits to the sliders will directly manipulate dimensions on the indices list. If any of the here listed dimensions is equal to width or height, it will be ignored. If not specified, adds slides for any dimension in indices.

TYPE: TensorDimensionIndexSliderArrayLike | None DEFAULT: None

class TensorViewFit

Bases: TensorViewFitExt, Archetype

Archetype: Configures how a selected tensor slice is shown on screen.

def __init__(scaling=None)

Create a new instance of the TensorViewFit archetype.

PARAMETER DESCRIPTION
scaling

How the image is scaled to fit the view.

TYPE: ViewFitLike | None DEFAULT: None

class ViewBlueprint

Bases: Archetype

Archetype: The description of a single view.

def __init__(class_identifier, *, display_name=None, space_origin=None, visible=None)

Create a new instance of the ViewBlueprint archetype.

PARAMETER DESCRIPTION
class_identifier

The class of the view.

TYPE: Utf8Like

display_name

The name of the view.

TYPE: Utf8Like | None DEFAULT: None

space_origin

The "anchor point" of this view.

Defaults to the root path '/' if not specified.

The transform at this path forms the reference point for all scene->world transforms in this view. I.e. the position of this entity path in space forms the origin of the coordinate system in this view. Furthermore, this is the primary indicator for heuristics on what entities we show in this view.

TYPE: EntityPathLike | None DEFAULT: None

visible

Whether this view is visible.

Defaults to true if not specified.

TYPE: BoolLike | None DEFAULT: None

class ViewContents

Bases: Archetype

Archetype: The contents of a View.

The contents are found by combining a collection of QueryExpressions.

+ /world/**           # add everything…
- /world/roads/**     # …but remove all roads…
+ /world/roads/main   # …but show main road

If there is multiple matching rules, the most specific rule wins. If there are multiple rules of the same specificity, the last one wins. If no rules match, the path is excluded.

Specifying a path without a + or - prefix is equivalent to +:

/world/**           # add everything…
- /world/roads/**   # …but remove all roads…
/world/roads/main   # …but show main road

The /** suffix matches the whole subtree, i.e. self and any child, recursively (/world/** matches both /world and /world/car/driver). Other uses of * are not (yet) supported.

Internally, EntityPathFilter sorts the rule by entity path, with recursive coming before non-recursive. This means the last matching rule is also the most specific one. For instance:

+ /world/**
- /world
- /world/car/**
+ /world/car/driver

The last rule matching /world/car/driver is + /world/car/driver, so it is included. The last rule matching /world/car/hood is - /world/car/**, so it is excluded. The last rule matching /world is - /world, so it is excluded. The last rule matching /world/house is + /world/**, so it is included.

def __init__(query)

Create a new instance of the ViewContents archetype.

PARAMETER DESCRIPTION
query

The QueryExpression that populates the contents for the view.

They determine which entities are part of the view.

TYPE: Utf8ArrayLike

class ViewportBlueprint

Bases: Archetype

Archetype: The top-level description of the viewport.

def __init__(*, root_container=None, maximized=None, auto_layout=None, auto_views=None, past_viewer_recommendations=None)

Create a new instance of the ViewportBlueprint archetype.

PARAMETER DESCRIPTION
root_container

The layout of the views

TYPE: UuidLike | None DEFAULT: None

maximized

Show one tab as maximized?

TYPE: UuidLike | None DEFAULT: None

auto_layout

Whether the viewport layout is determined automatically.

If true, the container layout will be reset whenever a new view is added or removed. This defaults to false and is automatically set to false when there is user determined layout.

TYPE: BoolLike | None DEFAULT: None

auto_views

Whether or not views should be created automatically.

If true, the viewer will only add views that it hasn't considered previously (as identified by past_viewer_recommendations) and which aren't deemed redundant to existing views. This defaults to false and is automatically set to false when the user adds views manually in the viewer.

TYPE: BoolLike | None DEFAULT: None

past_viewer_recommendations

Hashes of all recommended views the viewer has already added and that should not be added again.

This is an internal field and should not be set usually. If you want the viewer from stopping to add views, you should set auto_views to false.

The viewer uses this to determine whether it should keep adding views.

TYPE: UInt64ArrayLike | None DEFAULT: None

class VisibleTimeRanges

Bases: VisibleTimeRangesExt, Archetype

Archetype: Configures what range of each timeline is shown on a view.

Whenever no visual time range applies, queries are done with "latest-at" semantics. This means that the view will, starting from the time cursor position, query the latest data available for each component type.

The default visual time range depends on the type of view this property applies to: - For time series views, the default is to show the entire timeline. - For any other view, the default is to apply latest-at semantics.

def __init__(ranges)

Create a new instance of the VisibleTimeRanges archetype.

PARAMETER DESCRIPTION
ranges

The time ranges to show for each timeline unless specified otherwise on a per-entity basis.

If a timeline is listed twice, a warning will be issued and the first entry will be used.

TYPE: VisibleTimeRangeArrayLike

class VisualBounds2D

Bases: VisualBounds2DExt, Archetype

Archetype: Controls the visual bounds of a 2D view.

Everything within these bounds are guaranteed to be visible. Somethings outside of these bounds may also be visible due to letterboxing.

If no visual bounds are set, it will be determined automatically, based on the bounding-box of the data or other camera information present in the view.

def __init__(*, x_range=None, y_range=None)

Create a new instance of the VisualBounds2D archetype.

PARAMETER DESCRIPTION
x_range

The minimum visible range of the X-axis (usually left and right bounds).

TYPE: Range1DLike | None DEFAULT: None

y_range

The minimum visible range of the Y-axis (usually left and right bounds).

TYPE: Range1DLike | None DEFAULT: None