isaaclab.ui.widgets#

Classes#

The following classes are part of the public isaaclab.ui.widgets API.

ImagePlot

An image plot widget to display live data.

LiveLinePlot

A 2D line plot widget to display live data.

ManagerLiveVisualizer

A interface object used to transfer data from a manager to a UI widget.

UiVisualizerBase

Base Class for components that support debug visualizations that requires access to some UI elements.

class isaaclab.ui.widgets.ImagePlot[source]#

Bases: UIWidgetWrapper

An image plot widget to display live data.

The mode frame in the following layout is only useful for depth images:

+-------------------------------------------------------+
|                  containing_frame                     |
|+-----------------------------------------------------+|
|                   main_plot_frame                     |
||+---------------------------------------------------+||
|||                    plot_frames                    |||
|||                                                   |||
|||               (Image Plot Data)                   |||
|||                                                   |||
|||+-------------------------------------------------+|||
|||                   mode_frame                      |||
|||    [Dropdown: Mode Selection]                     |||
|||    [Collapsible: Manual Normalization Options]    |||
||+---------------------------------------------------+||
|+-----------------------------------------------------+|
+-------------------------------------------------------+

Methods:

__init__([image, label, widget_height, ...])

Create an XY plot UI Widget with axis scaling, legends, and support for multiple plots.

__new__(*args, **kwargs)

__init__(image: ndarray | None = None, label: str = '', widget_height: int = 200, min_value: float = 0.0, max_value: float = 1.0)[source]#

Create an XY plot UI Widget with axis scaling, legends, and support for multiple plots.

Overlapping data is most accurately plotted when centered in the frame with reasonable axis scaling. Pressing down the mouse gives the x and y values of each function at an x coordinate.

Parameters:
  • image – Image to display

  • label – Short descriptive text to the left of the plot

  • widget_height – Height of the plot in pixels

  • min_value – Minimum value for manual normalization/colorization. Defaults to 0.0.

  • max_value – Maximum value for manual normalization/colorization. Defaults to 1.0.

classmethod __new__(*args, **kwargs)#
class isaaclab.ui.widgets.LiveLinePlot[source]#

Bases: UIWidgetWrapper

A 2D line plot widget to display live data.

This widget is used to display live data in a 2D line plot. It can be used to display multiple series in the same plot.

The widget uses the following layout:

+-------------------------------------------------------+
|                  containing_frame                     |
|+-----------------------------------------------------+|
|                   main_plot_frame                     |
||+---------------------------------------------------+||
|||         plot_frames + grid lines (Z_stacked)      |||
|||               (Live Plot Data)                    |||
|||+-------------------------------------------------+|||
|||                   legends_frame                   |||
|||    [x][Series 1] [x][Series 2] [ ][Series 3]      |||
|||+-------------------------------------------------+|||
|||                   limits_frame                    |||
|||        [Y-Limits] [min] [max] [Autoscale]         |||
|||+-------------------------------------------------+|||
|||                   filter_frame                    |||
|+-----------------------------------------------------+|
+-------------------------------------------------------+

Methods:

__init__(y_data[, y_min, y_max, ...])

Create a new LiveLinePlot widget.

__new__(*args, **kwargs)

__init__(y_data: list[list[float]], y_min: float = -10, y_max: float = 10, plot_height: int = 150, show_legend: bool = True, legends: list[str] | None = None, max_datapoints: int = 200)[source]#

Create a new LiveLinePlot widget.

Parameters:
  • y_data – A list of lists of floats containing the data to plot. Each list of floats represents a series in the plot.

  • y_min – The minimum y value to display. Defaults to -10.

  • y_max – The maximum y value to display. Defaults to 10.

  • plot_height – The height of the plot in pixels. Defaults to 150.

  • show_legend – Whether to display the legend. Defaults to True.

  • legends – A list of strings containing the legend labels for each series. If None, the default labels are “Series_0”, “Series_1”, etc. Defaults to None.

  • max_datapoints – The maximum number of data points to display. If the number of data points exceeds this value, the oldest data points are removed. Defaults to 200.

classmethod __new__(*args, **kwargs)#
class isaaclab.ui.widgets.ManagerLiveVisualizer[source]#

Bases: UiVisualizerBase

A interface object used to transfer data from a manager to a UI widget.

This class handles the creation of UI Widgets for selected terms given a ManagerLiveVisualizerCfg. It iterates through the terms of the manager and creates a visualizer for each term. If the term is a single variable or a multi-variable signal, it creates a LiveLinePlot. If the term is an image (2D or RGB), it creates an ImagePlot. The visualizer can be toggled on and off using the ManagerLiveVisualizerCfg.debug_vis flag in the configuration.

Methods:

__init__(manager[, cfg])

Initialize ManagerLiveVisualizer.

__new__(*args, **kwargs)

__init__(manager: ~isaaclab.managers.manager_base.ManagerBase, cfg: ~isaaclab.ui.widgets.manager_live_visualizer.ManagerLiveVisualizerCfg = ManagerLiveVisualizerCfg(debug_vis=False, manager_name=<dataclasses._MISSING_TYPE object>, term_names=None))[source]#

Initialize ManagerLiveVisualizer.

Parameters:
  • manager – The manager with terms to be plotted. The manager must have a get_active_iterable_terms() method.

  • cfg – The configuration file used to select desired manager terms to be plotted.

classmethod __new__(*args, **kwargs)#
class isaaclab.ui.widgets.UiVisualizerBase[source]#

Bases: object

Base Class for components that support debug visualizations that requires access to some UI elements.

This class provides a set of functions that can be used to assign ui interfaces.

The following functions are provided:

  • set_debug_vis(): Assigns a debug visualization interface. This function is called by the main UI

    when the checkbox for debug visualization is toggled.

  • set_vis_frame(): Assigns a small frame within the isaac lab tab that can be used to visualize debug

    information. Such as e.g. plots or images. It is called by the main UI on startup to create the frame.

  • set_window(): Assigngs the main window that is used by the main UI. This allows the user

    to have full controller over all UI elements. But be warned, with great power comes great responsibility.

Methods:

__new__(*args, **kwargs)

__init__()

classmethod __new__(*args, **kwargs)#
__init__()#