motrixsim.viewer#
Exceptions:
Base exception for viewer errors |
|
Raise when invalid arguments are provided |
|
Raise when the viewer fails to launch |
Functions:
|
Launch a managed viewer with optional model and data. |
- exception motrixsim.viewer.ViewerError#
基类:
ExceptionBase exception for viewer errors
- exception motrixsim.viewer.ViewerInvalidArgumentError#
基类:
ViewerErrorRaise when invalid arguments are provided
- exception motrixsim.viewer.ViewerLaunchError#
基类:
ViewerErrorRaise when the viewer fails to launch
- motrixsim.viewer.launch(model=None, data=None, callback=None)#
Launch a managed viewer with optional model and data.
This function provides a simplified interface similar to MuJoCo's managed viewer. It blocks until the viewer window is closed, automatically handling the physics simulation loop and rendering.
- 参数:
model (SceneModel, optional) -- The scene model to simulate and visualize. If not provided, loads a default sample model.
data (SceneData, optional) -- The scene data containing the initial state. If not provided, creates default data from the model.
callback (callable, optional) -- A callback function called at each physics step.