isaaclab_newton.cloner#
Functions
Temporarily extend every world built by Newton replication. |
Builder Utilities#
- isaaclab_newton.cloner.newton_builder_world_hook(hook: Callable[[newton.ModelBuilder, int, list[float], list[float]], None]) Iterator[None][source]#
Temporarily extend every world built by Newton replication.
The callback must not already be registered. On exit, the context removes only its callback and preserves hooks owned by other callers.
- Parameters:
hook¶ – Callback receiving the builder, world index, world position [m], and world orientation quaternion in xyzw order during replication.
- Yields:
Control while the callback is registered.
- Raises:
RuntimeError – If the callback is already registered.
Additional Public Classes#
The following classes are part of the public isaaclab_newton.cloner API.
Queue and run Newton replication work for one stage. |
- class isaaclab_newton.cloner.NewtonReplicateContext[source]#
Bases:
objectQueue and run Newton replication work for one stage.
Methods:
- __init__(stage: pxr.Usd.Stage, *, device: str = 'cpu', up_axis: str = 'Z', load_visual_shapes: bool | None = None, commit_to_manager: bool = True)[source]#
Initialize the context.
- Parameters:
stage¶ – USD stage containing source assets.
device¶ – Device used by the finalized Newton model builder.
up_axis¶ – Up axis for the Newton model builder.
load_visual_shapes¶ – Whether to import visual-only geometry. If
None, read from the activeNewtonCfg, which itself defaults to importing them only when a renderer or visualizer is active.commit_to_manager¶ – Whether
replicate()should publish the builder toNewtonManager.
- classmethod __new__(*args, **kwargs)#