Python guide and API reference#

Authoring#

create_stage

create_stage() -> bool

open_stage

str) -> bool

save_stage

str) -> bool

export_stage_to_string

export_stage_to_string() -> str

import_stage_from_string

str) -> bool

close_stage

close_stage() -> bool

add_reference_to_stage

str, type_name: str = 'Xform') -> bool

define_prim

str = 'Xform') -> bool

move_prim

str) -> bool

remove_prim

str) -> bool

create_prim_attribute

str, type_name: str) -> bool

remove_prim_attribute

str) -> bool

set_parameter

str, value: bool | int | int | float | str) -> None

get_parameter

str) -> bool | int | int | float | str

isaacsim.foundation.ovsim.control.authoring.create_stage() → bool#

Create an empty OpenUSD stage and make it active.

Returns:

Whether the created stage is valid.

isaacsim.foundation.ovsim.control.authoring.open_stage(usd_path: str) → bool#

Open a USD stage and make it active.

Parameters:

usd_path – Path or URL of the USD layer to open.

Returns:

Whether the opened stage is valid.

isaacsim.foundation.ovsim.control.authoring.save_stage(usd_path: str) → bool#

Save the active authoring stage.

Parameters:

usd_path – Destination path for the root USD layer.

Returns:

Whether the stage was saved successfully.

isaacsim.foundation.ovsim.control.authoring.export_stage_to_string() → str#

Export the active authoring stage as USDA text.

Returns:

Serialized USDA content.

isaacsim.foundation.ovsim.control.authoring.import_stage_from_string(usd_string: str) → bool#

Import serialized USDA content and make the stage active.

Parameters:

usd_string – Serialized USDA content.

Returns:

Whether the imported stage is valid.

isaacsim.foundation.ovsim.control.authoring.close_stage() → bool#

Close retained authoring and simulation stages.

Returns:

Whether the active stage was closed successfully.

isaacsim.foundation.ovsim.control.authoring.add_reference_to_stage(
usd_path: str,
path: str,
type_name: str = 'Xform',
) → bool#

Add a reference to the active authoring stage.

Parameters:
  • usd_path – Path or URL of the referenced USD layer.

  • path – Absolute prim path that receives the reference.

  • type_name – Prim type to define when the target path does not exist.

Returns:

Whether the reference was added successfully.

isaacsim.foundation.ovsim.control.authoring.define_prim(path: str, type_name: str = 'Xform') → bool#

Define a prim on the active authoring stage.

Parameters:
  • path – Absolute path of the prim to define.

  • type_name – USD or Isaac Sim prim type to create.

Returns:

Whether the prim was defined successfully.

isaacsim.foundation.ovsim.control.authoring.move_prim(target_path: str, destination_path: str) → bool#

Move a prim on the active authoring stage.

Parameters:
  • target_path – Absolute path of the prim to move.

  • destination_path – Absolute destination path.

Returns:

Whether the prim was moved successfully.

isaacsim.foundation.ovsim.control.authoring.remove_prim(path: str) → bool#

Remove a prim from the active authoring stage.

Parameters:

path – Absolute path of the prim to remove.

Returns:

Whether the prim was removed successfully.

isaacsim.foundation.ovsim.control.authoring.create_prim_attribute(
path: str,
attribute_name: str,
type_name: str,
) → bool#

Create an attribute on a prim in the active authoring stage.

Parameters:
  • path – Absolute path of the target prim.

  • attribute_name – Name of the attribute to create.

  • type_name – USD type name for the attribute.

Returns:

Whether the attribute was created successfully.

isaacsim.foundation.ovsim.control.authoring.remove_prim_attribute(path: str, attribute_name: str) → bool#

Remove an attribute from a prim in the active authoring stage.

Parameters:
  • path – Absolute path of the target prim.

  • attribute_name – Name of the attribute to remove.

Returns:

Whether the attribute was removed successfully.

isaacsim.foundation.ovsim.control.authoring.set_parameter(
provider: str,
parameter_name: str,
value: bool | int | int | float | str,
) → None#

Accept an authoring provider parameter without changing stage state.

Parameters:
  • provider – Provider identifier reserved for future authoring configuration.

  • parameter_name – Provider-specific parameter name.

  • value – Parameter value.

Note

The current implementation accepts and ignores all parameters.

isaacsim.foundation.ovsim.control.authoring.get_parameter(
provider: str,
parameter_name: str,
) → bool | int | int | float | str#

Query a retained stage identifier or pointer.

Parameters:
  • provider – Provider identifier. The supported value is "stage".

  • parameter_name – One of "openusd-stage-id", "openusd-stage-ptr", "ovstage-stage-id", or "ovstage-stage-ptr".

Returns:

Requested identifier or pointer. A missing stage uses -1 for its identifier and zero for its pointer.

Raises:

ValueError – If the provider or parameter name is unsupported.

Simulation#

initialize

initialize() -> None

play

play() -> None

pause

pause() -> None

stop

stop() -> None

step

step() -> None

invalidate

invalidate() -> None

set_parameter

str, value: bool | int | int | float | str) -> None

get_parameter

str) -> bool | int | int | float | str

isaacsim.foundation.ovsim.control.simulation.initialize() → None#

Copy the active OpenUSD stage into a retained OVStage simulation snapshot.

isaacsim.foundation.ovsim.control.simulation.play() → None#

Accept a play request without changing simulation state.

isaacsim.foundation.ovsim.control.simulation.pause() → None#

Accept a pause request without changing simulation state.

isaacsim.foundation.ovsim.control.simulation.stop() → None#

Accept a stop request without changing simulation state.

isaacsim.foundation.ovsim.control.simulation.step() → None#

Accept a manual simulation step request without changing simulation state.

isaacsim.foundation.ovsim.control.simulation.invalidate() → None#

Close and release the retained OVStage simulation snapshot, if one exists.

isaacsim.foundation.ovsim.control.simulation.set_parameter(
provider: str,
parameter_name: str,
value: bool | int | int | float | str,
) → None#

Reject a simulation provider parameter because configuration is not implemented.

Parameters:
  • provider – Provider identifier.

  • parameter_name – Provider-specific parameter name.

  • value – Parameter value.

Raises:

RuntimeError – Always.

isaacsim.foundation.ovsim.control.simulation.get_parameter(
provider: str,
parameter_name: str,
) → bool | int | int | float | str#

Reject a simulation provider query because configuration is not implemented.

Parameters:
  • provider – Provider identifier.

  • parameter_name – Provider-specific parameter name.

Raises:

RuntimeError – Always.

Data#

read

str, timestamp: float | None = None) -> list[str] | list[list[str]] | warp.array

write

str, values: str | collections.abc.Sequence[str] | collections.abc.Sequence[collections.abc.Sequence[str]] | warp.array, timestamp: float | None = None) -> None

isaacsim.foundation.ovsim.data.read(
paths: str | collections.abc.Sequence[str],
attribute_name: str,
timestamp: float | None = None,
) → list[str] | list[list[str]] | warp.array#

Read one attribute from one or more prims on the active stage.

Parameters:
  • paths – Absolute prim path or paths to read.

  • attribute_name – Name of the attribute or registered facade property to read.

  • timestamp – Optional time code in stage time units. The current implementation reads default-time values.

Returns:

Values read for the selected prim paths.

isaacsim.foundation.ovsim.data.write(
paths: str | collections.abc.Sequence[str],
attribute_name: str,
values: str | collections.abc.Sequence[str] | collections.abc.Sequence[collections.abc.Sequence[str]] | warp.array,
timestamp: float | None = None,
) → None#

Write one attribute on one or more prims on the active stage.

Parameters:
  • paths – Absolute prim path or paths to modify.

  • attribute_name – Name of the attribute or registered facade property to write.

  • values – Values to write to the selected prim paths.

  • timestamp – Optional time code in stage time units. The current implementation writes default-time values.