isaaclab_contrib.mdp#

Actions#

Classes

ThrustActionCfg

Configuration for the thrust action term.

ThrustAction

Thrust action term that applies the processed actions as thrust commands.

Thrust Action Configuration#

class isaaclab_contrib.mdp.actions.thrust_actions_cfg.ThrustActionCfg[source]#

Bases: ActionTermCfg

Configuration for the thrust action term.

See ThrustAction for more details.

Attributes:

asset_name

Name or regex expression of the asset that the action will be mapped to.

scale

Scale factor for the action (float or dict of regex expressions).

debug_vis

Whether to visualize debug information.

clip

Clip range for the action (dict of regex expressions).

offset

Offset factor for the action (float or dict of regex expressions).

preserve_order

Whether to preserve the order of the asset names in the action output.

use_default_offset

Whether to use default thrust (e.g.

asset_name: str#

Name or regex expression of the asset that the action will be mapped to.

scale: float | dict[str, float]#

Scale factor for the action (float or dict of regex expressions). Defaults to 1.0.

debug_vis: bool#

Whether to visualize debug information. Defaults to False.

clip: dict[str, tuple] | None#

Clip range for the action (dict of regex expressions). Defaults to None.

offset: float | dict[str, float]#

Offset factor for the action (float or dict of regex expressions). Defaults to 0.0.

preserve_order: bool#

Whether to preserve the order of the asset names in the action output. Defaults to False.

use_default_offset: bool#

Whether to use default thrust (e.g. hover thrust) configured in the articulation asset as offset. Defaults to True.

If True, this flag results in overwriting the values of offset to the default thrust values from the articulation asset.

Thrust Action Implementation#

class isaaclab_contrib.mdp.actions.thrust_actions.ThrustAction[source]#

Bases: ActionTerm

Thrust action term that applies the processed actions as thrust commands. Actions are processed by applying an affine transformation (scaling and offset) and clipping.

Attributes:

cfg

The configuration of the action term.

device

Device on which to perform computations.

export_IO_descriptor

Whether to export the IO descriptor for the action term.

has_debug_vis_implementation

Whether the action term has a debug visualization implemented.

num_envs

Number of environments.

action_dim

Dimension of the action term.

raw_actions

The input/raw actions sent to the term.

processed_actions

The actions computed by the term after applying any processing.

IO_descriptor

The IO descriptor of the action term.

Methods:

__init__(cfg, env)

Initialize the action term.

serialize()

General serialization call.

set_debug_vis(debug_vis)

Sets whether to visualize the action term data.

process_actions(actions)

Process actions by applying scaling, offset, and clipping.

apply_actions()

Apply the processed actions as thrust commands.

reset([env_ids])

Reset the action term.

cfg: thrust_actions_cfg.ThrustActionCfg#

The configuration of the action term.

__init__(cfg: thrust_actions_cfg.ThrustActionCfg, env: ManagerBasedEnv) None[source]#

Initialize the action term.

Parameters:
  • cfg – The configuration object.

  • env – The environment instance.

property device: str#

Device on which to perform computations.

property export_IO_descriptor: bool#

Whether to export the IO descriptor for the action term.

property has_debug_vis_implementation: bool#

Whether the action term has a debug visualization implemented.

property num_envs: int#

Number of environments.

serialize() dict#

General serialization call. Includes the configuration dict.

set_debug_vis(debug_vis: bool) bool#

Sets whether to visualize the action term data. :param debug_vis: Whether to visualize the action term data.

Returns:

Whether the debug visualization was successfully set. False if the action term does not support debug visualization.

property action_dim: int#

Dimension of the action term.

property raw_actions: torch.Tensor#

The input/raw actions sent to the term.

property processed_actions: torch.Tensor#

The actions computed by the term after applying any processing.

property IO_descriptor: GenericActionIODescriptor#

The IO descriptor of the action term.

process_actions(actions: torch.Tensor)[source]#

Process actions by applying scaling, offset, and clipping.

apply_actions()[source]#

Apply the processed actions as thrust commands.

reset(env_ids: Sequence[int] | None = None) None[source]#

Reset the action term.