isaaclab.visualizers#

Visualizer configurations and implementations.

Custom visualizers implement initialize(sim, *, cameras) and reset(soft=False). Initialization receives the simulation owner explicitly. Call super().initialize(sim, cameras=cameras) to retain the simulation as self._sim and bind scene data. Resolve backend-specific resources in the implementation; core lifecycle dispatch does not import or construct them. Hard resets can reacquire resources through self._sim.get_or_create_backend(...) and access the stage through self._sim.stage. Rendering uses the resolved resources.

Additional Public Classes#

The following classes are part of the public isaaclab.visualizers API.

BaseVisualizer

Base class for all visualizer backends.

VisualizerCfg

Base configuration for all visualizer backends.

WindowCfg

Native window presentation, independent of the camera's image resolution.

PerspectiveCameraCfg

Initial pose and optics for an interactive perspective camera.

SceneCameraCfg

Select an existing scene camera's output as the visualizer's main view.

ImageViewCfg

A shared image selection consumed by windows and recorders.

ImageView

Own one composed GPU image shared by its display and recording consumers.

class isaaclab.visualizers.BaseVisualizer[source]#

Bases: ABC

Base class for all visualizer backends.

Lifecycle: __init__() -> initialize() -> step() (repeated) -> close()

Methods:

__init__(cfg)

Initialize visualizer with config.

__new__(*args, **kwargs)

__init__(cfg: VisualizerCfg)[source]#

Initialize visualizer with config.

Parameters:

cfg – Visualizer configuration.

classmethod __new__(*args, **kwargs)#
class isaaclab.visualizers.VisualizerCfg[source]#

Bases: object

Base configuration for all visualizer backends.

Note

This configuration can be used directly as default_visualizer_cfg to provide shared defaults. To create a visualizer, use a concrete config from isaaclab_visualizers, such as KitVisualizerCfg or NewtonGLVisualizerCfg.

Methods:

__new__(*args, **kwargs)

__init__([class_type, cloning_contexts, ...])

classmethod __new__(*args, **kwargs)#
__init__(class_type: type[BaseVisualizer] | str | None = <factory>, cloning_contexts: tuple[type[ReplicateContext] | str, ...] = <factory>, view: ImageViewCfg | None = <factory>, window: WindowCfg = <factory>, headless: bool = <factory>, cameras: list[PerspectiveCameraCfg | SceneCameraCfg] | None = <factory>, eye: tuple[float, float, float] = <factory>, lookat: tuple[float, float, float] = <factory>, focal_length: float = <factory>, background_color: tuple[float, float, float] | None = <factory>, streaming_view: bool = <factory>, streaming_sensor_prim_path: str | None = <factory>, streaming_envs: int | list[int] = <factory>, streaming_gt_types: tuple[str, ...] = <factory>, streaming_depth_min: float = <factory>, streaming_depth_max: float = <factory>, max_visible_envs: int | None = <factory>, visible_env_indices: list[int] | None = <factory>, randomly_sample_visible_envs: bool = <factory>, enable_markers: bool = <factory>, enable_live_plots: bool = <factory>, live_plots_update_interval: int = <factory>, visualizer_type: str | None = <factory>) → None#
class isaaclab.visualizers.PerspectiveCameraCfg[source]#

Bases: object

Initial pose and optics for an interactive perspective camera.

Newton RTX launch preparation expands this declaration into a scene CameraCfg. Newton GL uses its native viewer camera.

Methods:

__new__(*args, **kwargs)

__init__([eye, lookat, focal_length])

classmethod __new__(*args, **kwargs)#
__init__(eye: tuple[float, float, float] = <factory>, lookat: tuple[float, float, float] = <factory>, focal_length: float = <factory>) → None#
class isaaclab.visualizers.SceneCameraCfg[source]#

Bases: object

Select an existing scene camera’s output as the visualizer’s main view.

This does not create a sensor. Declare its pose, optics, and renderer in the scene’s CameraCfg.

Methods:

__new__(*args, **kwargs)

__init__([prim_path])

classmethod __new__(*args, **kwargs)#
__init__(prim_path: str = <factory>) → None#
class isaaclab.visualizers.ImageViewCfg[source]#

Bases: object

A shared image selection consumed by windows and recorders.

Reusing this declaration shares one runtime view within a simulation, including across copies of an environment configuration. Use isaaclab.utils.replace() to declare an independent view.

Methods:

__new__(*args, **kwargs)

__init__([class_type, source, envs, ...])

classmethod __new__(*args, **kwargs)#
__init__(class_type: str = <factory>, source: str | ~isaaclab.visualizers.visualizer_cfg.PerspectiveCameraCfg = <factory>, envs: tuple[int, ...] = <factory>, channels: tuple[str, ...] = <factory>, depth_range: tuple[float, float] = <factory>) → None#
class isaaclab.visualizers.ImageView[source]#

Own one composed GPU image shared by its display and recording consumers.

The scene retains ownership of sensors and their capture cadence. Perspective producers write device pixels through render. Reading twice for the same frame reuses the composed image; only read_rgb() transfers pixels to the host.

Methods:

__init__(cfg, *[, camera])

Bind a view declaration to a scene sensor or an initially unbound perspective producer.

read(frame_id)

Return native RGB/RGBA perspective pixels or composed uint8 [H, W, 4] sensor tiles; None for no rows.

read_rgb(frame_id)

Download the composed frame once for CPU encoders or network transports.

invalidate()

Invalidate cached pixels after camera movement, a source update, or a simulation reset.

__new__(*args, **kwargs)

__init__(cfg: ImageViewCfg, *, camera: Camera | BaseRayCasterCamera | None = None) → None[source]#

Bind a view declaration to a scene sensor or an initially unbound perspective producer.

read(frame_id: int | float) → wp.array | None[source]#

Return native RGB/RGBA perspective pixels or composed uint8 [H, W, 4] sensor tiles; None for no rows.

read_rgb(frame_id: int | float) → ndarray | None[source]#

Download the composed frame once for CPU encoders or network transports.

invalidate() → None[source]#

Invalidate cached pixels after camera movement, a source update, or a simulation reset.

classmethod __new__(*args, **kwargs)#
class isaaclab.visualizers.WindowCfg[source]#

Bases: object

Native window presentation, independent of the camera’s image resolution.

Methods:

__new__(*args, **kwargs)

__init__([size, fps])

classmethod __new__(*args, **kwargs)#
__init__(size: tuple[int, int] = <factory>, fps: float = <factory>) → None#