unilab.envs.motion_tracking.g1¶
Motion tracking environments for Unitree G1.
- class unilab.envs.motion_tracking.g1.G1MotionTrackingCfg[source]¶
Bases:
G1BaseCfgConfiguration for G1 motion tracking environment.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- motion_file: str | list[str] = '/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz'¶
- anchor_body_name: str = 'torso_link'¶
- body_names: tuple[str, ...] = ('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link')¶
- sampling_mode: Literal['start', 'clip_start', 'uniform', 'adaptive', 'mixed'] = 'adaptive'¶
- sampling_start_ratio: float = 0.0¶
- truncate_on_clip_end: bool = False¶
- max_episode_seconds: float = 10.0¶
- reward_config: RewardConfig¶
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- domain_rand: Domain_Rand¶
- joint_position_range: tuple[float, float] = (-0.1, 0.1)¶
- anchor_pos_z_threshold: float = 0.25¶
- anchor_ori_threshold: float = 0.8¶
- ee_body_pos_z_threshold: float = 0.25¶
- ee_body_names: tuple[str, ...] = ('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link')¶
- undesired_contact_z_threshold: float = 0.05¶
- terminate_on_undesired_contacts: bool = False¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- noise_config: NoiseConfig¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1MotionTrackingDeployEnv[source]¶
Bases:
G1MotionTrackingEnvDeploy-oriented G1 motion tracking env with unitree_rl_lab mimic actor inputs.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1MotionTrackingDeployEnvCfg[source]¶
Bases:
G1MotionTrackingCfgRegistered deploy configuration for G1 motion tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1MotionTrackingEnv[source]¶
Bases:
G1BaseEnvG1 Motion Tracking Environment.
- Parameters:
cfg (
G1MotionTrackingCfg)
- __init__(cfg, num_envs=1, backend_type='mujoco')[source]¶
- Parameters:
cfg (
G1MotionTrackingCfg)
- apply_action(actions, state)[source]¶
子类实现:action → ctrl
- Parameters:
actions (
ndarray)state (
NpEnvState)
- Return type:
- property obs_groups_spec: dict[str, int]¶
101}.
Subclasses MUST override this property.
- Type:
Return observation group dimensions, e.g. {“obs”
- Type:
98, “critic”
- update_state(state)[source]¶
子类实现:计算 obs/reward/terminated
- Parameters:
state (
NpEnvState)- Return type:
- class unilab.envs.motion_tracking.g1.G1MotionTrackingEnvCfg[source]¶
Bases:
G1MotionTrackingCfgRegistered configuration for G1 motion tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1MotionTrackingSACCfg[source]¶
Bases:
G1MotionTrackingCfgConfig for SAC-based motion tracking (identical fields, separate registry entry).
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1MotionTrackingSACEnv[source]¶
Bases:
G1MotionTrackingEnvG1 Motion Tracking environment for FastSAC training.
Extends the PPO motion-tracking environment with
base_lin_velappended to the critic observation, matching holosoma’s asymmetric actor-critic WBT design.The motrix backend is registered for sim2sim eval/playback only — checkpoints trained on mujoco can be replayed via motrix’s native renderer through
eval --sim motrix.- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1WBTObsCfg[source]¶
Bases:
G1MotionTrackingSACCfgSAC whole-body tracking with sim2real obs / DR / reward extensions.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (ObsNoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (ObsDomainRand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- noise_config: ObsNoiseConfig¶
- domain_rand: ObsDomainRand¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/dance1_subject2_part.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (ObsNoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (ObsDomainRand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- reward_config: RewardConfig¶
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1WBTObsEnv[source]¶
Bases:
G1MotionTrackingSACEnvSAC WBT with deploy-aligned obs, proprio history, and extra DR/rewards.
All extensions live in this subclass — base classes are untouched. Flags on
G1WBTObsCfgare toggled from the task yaml.- Parameters:
cfg (
G1WBTObsCfg)num_envs (
int)backend_type (
str)
- __init__(cfg, num_envs=1, backend_type='mujoco')[source]¶
- Parameters:
cfg (
G1WBTObsCfg)num_envs (
int)backend_type (
str)
- class unilab.envs.motion_tracking.g1.G1FlipTrackingCfg[source]¶
Bases:
G1MotionTrackingCfgConfig profile for flip tracking clips.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- motion_file: str | list[str] = '/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_360_001__A304.npz'¶
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- joint_position_range: tuple[float, float] = (0.0, 0.0)¶
- sampling_mode: Literal['start', 'clip_start', 'uniform', 'adaptive', 'mixed'] = 'start'¶
- terminate_on_undesired_contacts: bool = True¶
- anchor_ori_threshold: float = 1000000000.0¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_360_001__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='start', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.25, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- reward_config: RewardConfig¶
- domain_rand: Domain_Rand¶
- noise_config: NoiseConfig¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1FlipTrackingEnv[source]¶
Bases:
G1MotionTrackingEnvG1 flip-tracking environment implementation.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1FlipTrackingEnvCfg[source]¶
Bases:
G1FlipTrackingCfgRegistered configuration for G1 flip tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_360_001__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='start', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.25, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1WallFlipTrackingCfg[source]¶
Bases:
G1FlipTrackingCfgConfig profile for wall-assisted G1 flip tracking clips.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- motion_file: str | list[str] = '/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_from_wall_104__A304.npz'¶
- sampling_mode: Literal['start', 'clip_start', 'uniform', 'adaptive', 'mixed'] = 'adaptive'¶
- anchor_pos_z_threshold: float = 0.5¶
- ee_body_pos_z_threshold: float = 0.5¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_from_wall_104__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.5, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.5, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- reward_config: RewardConfig¶
- domain_rand: Domain_Rand¶
- noise_config: NoiseConfig¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1WallFlipTrackingEnv[source]¶
Bases:
G1MotionTrackingEnvG1 wall flip-tracking environment implementation.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1WallFlipTrackingEnvCfg[source]¶
Bases:
G1WallFlipTrackingCfgRegistered configuration for G1 wall flip tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_from_wall_104__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.5, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.5, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1FlipTrackingSACCfg[source]¶
Bases:
G1FlipTrackingCfgFlip tracking cfg for SAC (identical fields, separate registry entry).
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_360_001__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='start', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.25, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1FlipTrackingSACEnv[source]¶
Bases:
G1MotionTrackingSACEnvFlip tracking env with the SAC asymmetric actor-critic obs layout.
The motrix backend is registered for sim2sim eval/playback only.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1WallFlipTrackingSACCfg[source]¶
Bases:
G1WallFlipTrackingCfgWall-flip tracking cfg for SAC (identical fields, separate registry entry).
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/flip_from_wall_104__A304.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(0.0, 0.0), anchor_pos_z_threshold=0.5, anchor_ori_threshold=1000000000.0, ee_body_pos_z_threshold=0.5, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=True)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1WallFlipTrackingSACEnv[source]¶
Bases:
G1MotionTrackingSACEnvWall-flip tracking env with the SAC asymmetric actor-critic obs layout.
The motrix backend is registered for sim2sim eval/playback only.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1ClimbTrackingCfg[source]¶
Bases:
G1MotionTrackingCfgConfig profile for the climb_20_z_scale_1 motion clip.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- motion_file: str | list[str] = '/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/climb_20_z_scale_1.0.npz'¶
- max_episode_seconds: float = 15.0¶
- anchor_pos_z_threshold: float = 0.5¶
- ee_body_pos_z_threshold: float = 0.5¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=15.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/climb_20_z_scale_1.0.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.5, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.5, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- reward_config: RewardConfig¶
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- domain_rand: Domain_Rand¶
- noise_config: NoiseConfig¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1ClimbTrackingEnv[source]¶
Bases:
G1MotionTrackingEnvG1 climb-tracking environment implementation.
- Parameters:
cfg (
G1MotionTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1ClimbTrackingEnvCfg[source]¶
Bases:
G1ClimbTrackingCfgRegistered configuration for G1 box-climb motion tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=15.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/climb_20_z_scale_1.0.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.5, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.5, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (RewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
- class unilab.envs.motion_tracking.g1.G1BoxTrackingCfg[source]¶
Bases:
G1MotionTrackingCfgConfiguration for the G1 large-box tracking task.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (BoxRewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
object_body_name (str)
object_pos_threshold (float)
object_ori_threshold (float)
- motion_file: str | list[str] = '/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/sub3_largebox_003_boxconverted.npz'¶
- object_body_name: str = 'largebox'¶
- object_pos_threshold: float = 0.25¶
- object_ori_threshold: float = 0.8¶
- reward_config: BoxRewardConfig¶
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/sub3_largebox_003_boxconverted.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False, object_body_name='largebox', object_pos_threshold=0.25, object_ori_threshold=0.8)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (BoxRewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
object_body_name (str)
object_pos_threshold (float)
object_ori_threshold (float)
- pose_randomization: PoseRandomization¶
- velocity_randomization: VelocityRandomization¶
- domain_rand: Domain_Rand¶
- noise_config: NoiseConfig¶
- control_config: ControlConfig¶
- sensor: Sensor¶
- asset: Asset¶
- class unilab.envs.motion_tracking.g1.G1BoxTrackingEnv[source]¶
Bases:
G1MotionTrackingEnvMotion tracking env extended with large-box state and rewards.
- Parameters:
cfg (
G1BoxTrackingCfg)
- __init__(cfg, num_envs=1, backend_type='mujoco')[source]¶
- Parameters:
cfg (
G1BoxTrackingCfg)
- class unilab.envs.motion_tracking.g1.G1BoxTrackingEnvCfg[source]¶
Bases:
G1BoxTrackingCfgRegistered config for G1 box tracking.
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (BoxRewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
object_body_name (str)
object_pos_threshold (float)
object_ori_threshold (float)
- __init__(scene=<factory>, sim_dt=0.006666666666666667, max_episode_seconds=10.0, ctrl_dt=0.02, render_spacing=1.0, render_offset_mode='grid', motrix_max_iterations=None, post_step_forward_sensor=False, control_config=<factory>, noise_config=<factory>, sensor=<factory>, asset=<factory>, motion_file='/home/admin1/ws/Eric/UniLab/src/unilab/assets/motions/g1/sub3_largebox_003_boxconverted.npz', anchor_body_name='torso_link', body_names=('pelvis', 'left_hip_roll_link', 'left_knee_link', 'left_ankle_roll_link', 'right_hip_roll_link', 'right_knee_link', 'right_ankle_roll_link', 'torso_link', 'left_shoulder_roll_link', 'left_elbow_link', 'left_wrist_yaw_link', 'right_shoulder_roll_link', 'right_elbow_link', 'right_wrist_yaw_link'), sampling_mode='adaptive', sampling_start_ratio=0.0, truncate_on_clip_end=False, reward_config=<factory>, pose_randomization=<factory>, velocity_randomization=<factory>, domain_rand=<factory>, joint_position_range=(-0.1, 0.1), anchor_pos_z_threshold=0.25, anchor_ori_threshold=0.8, ee_body_pos_z_threshold=0.25, ee_body_names=('left_ankle_roll_link', 'right_ankle_roll_link', 'left_wrist_yaw_link', 'right_wrist_yaw_link'), undesired_contact_z_threshold=0.05, terminate_on_undesired_contacts=False, object_body_name='largebox', object_pos_threshold=0.25, object_ori_threshold=0.8)¶
- Parameters:
scene (SceneCfg)
sim_dt (float)
max_episode_seconds (float)
ctrl_dt (float)
render_spacing (
float)render_offset_mode (
str)post_step_forward_sensor (
bool)control_config (ControlConfig)
noise_config (NoiseConfig)
sensor (Sensor)
asset (Asset)
motion_file (str | list[str])
anchor_body_name (str)
body_names (tuple[str, …])
sampling_mode (Literal[‘start’, ‘clip_start’, ‘uniform’, ‘adaptive’, ‘mixed’])
sampling_start_ratio (float)
truncate_on_clip_end (bool)
reward_config (BoxRewardConfig)
pose_randomization (PoseRandomization)
velocity_randomization (VelocityRandomization)
domain_rand (Domain_Rand)
joint_position_range (tuple[float, float])
anchor_pos_z_threshold (float)
anchor_ori_threshold (float)
ee_body_pos_z_threshold (float)
ee_body_names (tuple[str, …])
undesired_contact_z_threshold (float)
terminate_on_undesired_contacts (bool)
object_body_name (str)
object_pos_threshold (float)
object_ori_threshold (float)
- class unilab.envs.motion_tracking.g1.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.envs.motion_tracking.g1.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.
- 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
G1 box tracking environment with object-aware motion imitation. |
|
Flip-specialized G1 motion tracking environment. |
|
SAC variants of the G1 flip / wall-flip tracking tasks. |
|
Motion loading with object state support for box tracking tasks. |
|
Motion loading and sampling for motion tracking tasks. |
|
G1 Motion Tracking Environment - Motion imitation task. |
|
G1 Whole-Body Tracking — sim2real-oriented SAC variant (task |
|
G1 Motion Tracking SAC Environment — thin SAC wrapper over G1MotionTrackingEnv. |