unilab.tasks.motion_tracking¶
Hydra-owned motion tracking tasks on the NumPy Manager-Based runtime.
- class unilab.tasks.motion_tracking.BoxMotionData[source]¶
Bases:
MotionDataMotion data with optional object state.
- Parameters:
- __init__(joint_pos, joint_vel, body_pos_w, body_quat_w, body_lin_vel_w, body_ang_vel_w, object_pos_w=None, object_quat_w=None, object_lin_vel_w=None, object_ang_vel_w=None)¶
- class unilab.tasks.motion_tracking.BoxMotionLoader[source]¶
Bases:
MotionLoaderMotion loader that also loads object state from NPZ files.
- __init__(motion_file, body_indices=None)[source]¶
Initialize motion loader.
- Parameters:
motion_file – Path to one NPZ file, or a sequence of NPZ files
body_indices – Optional indices into the NPZ body axis. The exported motion files currently keep MuJoCo body-id layout, so these indices are expected to follow that convention.
- make_motion_data_buffer(num_frames)[source]¶
Allocate a reusable
MotionDatabuffer for frame-index gathers.- Parameters:
num_frames (
int)- Return type:
- get_motion_at_frame(frame_idx, out=None)[source]¶
Get motion data at specified frame indices.
- Parameters:
frame_idx (
ndarray) – Frame indices (N,)out (
MotionData|None) – Optional reusable output buffer.
- Return type:
- Returns:
MotionData at specified frames
Modules