MCPcopy Create free account

hub / github.com/pollen-robotics/microduck_rl / functions

Functions681 in github.com/pollen-robotics/microduck_rl

Methodbuild
(self, entity, target_ids, target_names)
src/mjlab_microduck/actuator/friction_dr_bam.py:60
Methodbuild
(self, entity, target_ids, target_names)
src/mjlab_microduck/actuator/friction_dr_bam.py:111
Methodbuild
(self, env: ManagerBasedRlEnv)
src/mjlab_microduck/tasks/mdp.py:4572
Methodbuild
(self, env: ManagerBasedRlEnv)
src/mjlab_microduck/tasks/mdp.py:4630
Methodbuild
(self, env: ManagerBasedRlEnv)
src/mjlab_microduck/tasks/mdp.py:5028
Methodbuild
(self, env: ManagerBasedRlEnv)
src/mjlab_microduck/tasks/mdp.py:5111
Methodbuild
(self, env: ManagerBasedRlEnv)
src/mjlab_microduck/tasks/mdp.py:6330
Functionbuild_manifest
A single-policy manifest the daemon loads without surprises. Only the constant-command family is publishable from here — a skill's network is fed
src/mjlab_microduck/publish/manifest.py:89
Functioncheck_onnx
Refuse a file the daemon would refuse at load: wrong widths, or one that is not 61 -> 14.
src/mjlab_microduck/publish/manifest.py:264
Functioncoasting_reward
Reward coasting: low leg-joint velocity while at target speed. Returns exp(-vel_error / vel_std²) × exp(-sum(joint_vel²) / stillness_std²). B
src/mjlab_microduck/tasks/mdp.py:1712
Functioncom_height_target
Reward for keeping the center of mass within a target height range. Returns positive reward when in range, negative penalty when outside.
src/mjlab_microduck/tasks/mdp.py:1132
Functioncom_over_support_foot
Reward gaussien : projection horizontale du CoM proche du pied d'appui, gaté sur la phase de frappe (kick_engagement). Apprend le transfert l
src/mjlab_microduck/tasks/mdp.py:2743
Functioncom_range_curriculum
Update CoM randomization range based on training progress. Gradually increases the CoM offset range so the robot first learns to walk with a
src/mjlab_microduck/tasks/mdp.py:3464
Functioncom_upward_velocity
Reward upward CoM velocity to incentivize dynamic standup motion. Gated by height: only active while the CoM is below `max_height` (the stand
src/mjlab_microduck/tasks/mdp.py:900
Methodcommand
(self)
src/mjlab_microduck/tasks/testbench_env_cfg.py:68
Methodcommand
(self)
src/mjlab_microduck/tasks/mdp.py:4993
Methodcommand
(self)
src/mjlab_microduck/tasks/mdp.py:5077
Methodcommand
(self)
src/mjlab_microduck/tasks/mdp.py:6271
Methodcompute
(self, dt: float)
src/mjlab_microduck/tasks/mdp.py:4996
Functioncontact_frequency_penalty
Penalize high frequency of contact changes to encourage slower stepping. Tracks the number of contact state changes per second and penalizes
src/mjlab_microduck/tasks/mdp.py:1761
Functioncrouch_forward_lean
Léger penché AVANT du tronc pendant l'accroupi (gaté par le blend crouch). Contre la bascule arrière induite par la flexion rapide des hanches. P
src/mjlab_microduck/tasks/mdp.py:1382
Functioncrouch_glide_height_by_phase
Reward principale : suit la cible de hauteur du tronc le long de la phase. La hauteur du CoM est calculée comme dans `com_height_target` (world z
src/mjlab_microduck/tasks/mdp.py:1232
Functioncrouch_glide_pose_by_phase
Gaussian match to a phase-interpolated joint pose (stand <-> crouch). Directive reward: tells the robot the exact joint configuration to be in at
src/mjlab_microduck/tasks/mdp.py:1336
Functioncrouch_glide_pose_l1
L1 bootstrap toward the phase-interpolated crouch pose (negative penalty). Constant gradient everywhere — gives the policy a direction to the tar
src/mjlab_microduck/tasks/mdp.py:1360
Functiondump_manifest
(manifest: dict[str, Any])
src/mjlab_microduck/publish/manifest.py:385
Functionevent_param_curriculum
Mutate an event term's params at scheduled steps. Mirror of termination_param_curriculum but for events. Uses the live EventManager term cfg
src/mjlab_microduck/tasks/mdp.py:4453
Functionexpand_bam_friction_fields
No-op startup event whose only purpose is the decorator above. bam's BamActuator (mjlab_frictionloss branch) writes a per-env friction budget
src/mjlab_microduck/tasks/mdp.py:3198
Functionface_down_prob_curriculum
Ramp face_down_prob on a reset event over training. Args: event_name: name of the event term using set_random_prone_orientation p
src/mjlab_microduck/tasks/mdp.py:4477
Functionfake_submit
(monkeypatch)
tests/test_hf_jobs_flag.py:96
Functionfallen_state_penalty
1.0 while FALLEN (weight it negative): a flat per-step tax on staying down. Without it, lying still is ~0/step while attempting recovery costs
src/mjlab_microduck/tasks/mdp.py:604
Functionfallen_too_long
Terminate envs that have been continuously FALLEN for `max_duration_s`. For envs that mix walking with fall recovery (velstand): the fell_over
src/mjlab_microduck/tasks/mdp.py:936
Functionfeet_air_time_upright
velocity template feet_air_time, zeroed while FALLEN (tilt > gate). velstand: a robot lying on its trunk can still tap its feet rhythmically
src/mjlab_microduck/tasks/mdp.py:527
Functionfeet_distance_penalty
Penalize the feet getting too close to each other in the horizontal plane. Returns ``clamp(min_dist - d, min=0)`` per env (use with a negative we
src/mjlab_microduck/tasks/mdp.py:5571
Functionfeet_flat_penalty
Penalize foot sites not being parallel to the ground. The foot site frame has Z+ pointing up when flat. We project a unit gravity vector (poi
src/mjlab_microduck/tasks/mdp.py:1463
Functionfeet_grounded_reward
Positive reward for feet contacting the ground (0, +0.5, or +1.0). Uses the contact sensor's `found` field. For the feet_ground_contact sensor
src/mjlab_microduck/tasks/mdp.py:1625
Functionfeet_tiptoe_alignment
Reward each foot site's local x-axis pointing downward — tiptoe stance. When flat, foot site x points roughly forward (horizontal). Pitching the
src/mjlab_microduck/tasks/mdp.py:1511
Methodfind_joints
(self, query)
tests/test_ground_pick_pose.py:34
Methodfind_joints
(self, pattern)
tests/test_wheel_glide.py:26
Functionfoot_air_time_safe
NaN-safe `foot_air_time` (see note above).
src/mjlab_microduck/tasks/mdp.py:5224
Functionfoot_contact_forces_safe
NaN-safe `foot_contact_forces` (see note above).
src/mjlab_microduck/tasks/mdp.py:5214
Functionfoot_height_safe
NaN-safe `foot_height` (see note above).
src/mjlab_microduck/tasks/mdp.py:5219
Functionfoot_step_penalty_when_standing
Penalise stepping when at zero command and the body is not being pushed. Symmetric counterpart to the air_time reward: - air_time gives +rew
src/mjlab_microduck/tasks/mdp.py:3892
Functionforward_lean_reward
Reward leaning slightly forward when pushing, to counteract the backward torque from skating strokes. Uses projected_gravity_b x-component as
src/mjlab_microduck/tasks/mdp.py:4944
Functionforward_speed_reward
Récompense la vitesse avant du tronc (conserver l'élan / ne pas freiner). Indépendante de la commande (la commande porte la phase, pas la vitesse
src/mjlab_microduck/tasks/mdp.py:1258
Functiongait_symmetry_penalty
Penalize lopsided left/right foot usage (one blade doing most of the work). With symmetry augmentation OFF, nothing stops the policy learning an
src/mjlab_microduck/tasks/mdp.py:4843
Functionget_allcollisions_spec
()
src/mjlab_microduck/robot/microduck_constants.py:65
Functionget_backlash_spec
()
src/mjlab_microduck/robot/microduck_constants.py:73
Functionget_ball_spec
()
src/mjlab_microduck/robot/microduck_constants.py:69
Methodget_command
(self, _name)
tests/test_ground_pick_pose.py:44
Methodget_command
(self, name)
tests/test_spin.py:120
Methodget_command
(self, _)
tests/test_head_pose_bias.py:49
Functionget_ground_pick_spec
()
src/mjlab_microduck/robot/microduck_constants.py:55
Functionget_rollers_backlash_spec
()
src/mjlab_microduck/robot/microduck_constants.py:81
Functionget_standup_spec
()
src/mjlab_microduck/robot/microduck_constants.py:51
Functionget_testbench_spec
()
src/mjlab_microduck/robot/testbench_constants.py:35
Functionget_walk_backlash_spec
()
src/mjlab_microduck/robot/microduck_constants.py:77
Functionget_walk_spec
()
src/mjlab_microduck/robot/microduck_constants.py:47
Functiongit_provenance
`commit`, `branch`, `dirty` of the checkout the export ran from, or `{}` outside git.
src/mjlab_microduck/publish/manifest.py:68
Functionglide_reward
Reward the GLIDE phase of a stride: coast on ONE blade with quiet legs. Nothing else rewards gliding — skating_air_time pays each swing, so the p
src/mjlab_microduck/tasks/mdp.py:4744
Functionground_pick_return_pose
Reward for returning to the standing pose after ground pick, weighted by the return phase. The return phase is the second half-cycle (sin < 0, ph
src/mjlab_microduck/tasks/mdp.py:2905
Functionground_pick_return_pose_phased
ground_pick_return_pose gaté par la up-gate segmentée (remontée+repos).
src/mjlab_microduck/tasks/mdp.py:3023
Functionground_pick_return_upright
Reward trunk verticality, weighted by the RETURN phase (stand-up aid). Same return weighting as ``ground_pick_return_pose`` (``max(0, -sin(2π·pha
src/mjlab_microduck/tasks/mdp.py:2939
Functionground_pick_return_upright_phased
ground_pick_return_upright gaté par la up-gate segmentée.
src/mjlab_microduck/tasks/mdp.py:3044
Functiongrounded_reward
Reward BOTH blades in contact — a classic swizzle stays grounded (no lifting). Mirror of single_support_reward but rewarding double support (n_co
src/mjlab_microduck/tasks/mdp.py:4822
Methodhandle
(self)
src/mjlab_microduck/sim/body_server.py:389
Functionhead_pose_bias_penalty
Penalize the time-averaged (DC) neck/head tracking error: -mean(|EMA(err)|). Companion to ``head_pose_tracking``, which scores the INSTANTANEOUS
src/mjlab_microduck/tasks/mdp.py:5229
Functionheading_hold_reward
Reward holding the SPAWN heading (go straight) — corrective, angle-based. Rewards the yaw ANGLE staying near the heading captured at reset:
src/mjlab_microduck/tasks/mdp.py:4874
Functionheading_tracking_reward
Reward for reducing heading error when cmd[2] encodes heading error. Returns exp(-cmd[2]² / std²). - At error = 0 (on heading): reward = 1.0.
src/mjlab_microduck/tasks/mdp.py:4634
Functionheight_l1_penalty
L1 companion to ``height_target_gaussian``.
src/mjlab_microduck/tasks/mdp.py:2454
Functionheight_progress
Potential-based height shaping: Δ min(trunk z, ceiling) per step. The z-axis companion to ``upright_progress`` (velstand crouch-endpoint less
src/mjlab_microduck/tasks/mdp.py:575
Functionheight_target_gaussian
Gaussian on trunk z against a single fixed target.
src/mjlab_microduck/tasks/mdp.py:2440
Functionhip_pitch_knee_vel_l2
Penalize hip_pitch and knee joint velocities (L2 squared). Walking requires rapid oscillation of these sagittal-plane joints. Skating uses hi
src/mjlab_microduck/tasks/mdp.py:1541
Methodident
(kind, name)
src/mjlab_microduck/sim/body_server.py:212
Methodinitialize
(self, mj_model, model, data, device)
src/mjlab_microduck/actuator/friction_dr_bam.py:85
Functioninterpolated_height_l1_penalty
L1 distance from a time-interpolated target height (negative — penalty). Same role as ``interpolated_pose_l1_penalty`` but on trunk z. Provides a
src/mjlab_microduck/tasks/mdp.py:2181
Functioninterpolated_height_target
Gaussian on trunk z vs a time-interpolated target height. Companion to ``interpolated_pose_target_match`` — same time-interpolation logic app
src/mjlab_microduck/tasks/mdp.py:2207
Functioninterpolated_pose_l1_penalty
L1 distance from a time-interpolated target pose (negative — used as penalty). Same interpolation schedule as ``interpolated_pose_target_match``
src/mjlab_microduck/tasks/mdp.py:2142
Functioninterpolated_pose_target_match
Gaussian on joint positions vs a time-interpolated target pose. Tracks a target that linearly interpolates from a source pose to a target pos
src/mjlab_microduck/tasks/mdp.py:2090
Functionip
()
tests/test_infer_policy_bam.py:23
Functionis_alive
Reward for staying alive (not terminated) Args: env: The environment Returns: Reward tensor of shape (num_envs,) - ones
src/mjlab_microduck/tasks/mdp.py:1119
Functionjoint_accelerations_l2
Penalize joint accelerations using L2 squared norm. Joint accelerations are computed using finite differences of joint velocities. Args:
src/mjlab_microduck/tasks/mdp.py:316
Functionjoint_deviation_l1
L1 penalty for joint positions deviating from their default (HOME). Returns sum of |joint_pos - default| over the selected joints. Unlike the
src/mjlab_microduck/tasks/mdp.py:1971
Functionjoint_pos_limit_proximity
L1 penalty for joint positions entering a ``margin`` (rad) band next to their *hard* range limits. The base ``joint_pos_limits`` reward only
src/mjlab_microduck/tasks/mdp.py:1989
Functionjoint_pos_rel_backlash
joint_pos_rel where the encoder reads through the backlash hinge. Returns (qpos[servo] + qpos[backlash]) - default[servo]. With biased=True t
src/mjlab_microduck/tasks/mdp.py:6184
Functionjoint_torque_rate_l2
Penalize rate of change in actuator torques (proxy for gearbox shock). Sudden torque spikes occur when the robot impacts the ground and actuators
src/mjlab_microduck/tasks/mdp.py:1601
Functionjoint_torques_l2
Penalize actuator forces (torques) to encourage energy-efficient motion. Args: env: The environment asset_cfg: Asset configu
src/mjlab_microduck/tasks/mdp.py:1579
Functionjoint_vel_l2_when_standing
Penalise leg joint velocities only when command is near zero. Targets the standing-shake problem: the policy makes rapid oscillating correcti
src/mjlab_microduck/tasks/mdp.py:3867
Functionjoint_vel_rel_backlash
joint_vel_rel where the encoder reads through the backlash hinge. The firmware derives present_velocity from encoder positions, so it also se
src/mjlab_microduck/tasks/mdp.py:6204
Functionkick_pose_track
Gaussienne sur la pose articulaire vs cible interpolée du shoot. Reward directif et symétrique : chaque phase impose la config articulaire ex
src/mjlab_microduck/tasks/mdp.py:2676
Functionkick_pose_track_l1
Bootstrap L1 vers la cible interpolée (gradient constant, pénalité<=0).
src/mjlab_microduck/tasks/mdp.py:2703
Functionleg_action_acceleration_l2
Penalize leg action accelerations (action_t - 2*action_{t-1} + action_{t-2}). Leg joints are indices 0-4 and 9-13 (10 joints total). Arg
src/mjlab_microduck/tasks/mdp.py:429
Functionleg_action_rate_l2
Penalize the rate of change of leg actions (action_t - action_{t-1}). Leg joints are indices 0-4 and 9-13 (10 joints total). Args:
src/mjlab_microduck/tasks/mdp.py:353
Functionleg_antisymmetry
Amorce le CISEAU des jambes (une avant / une arrière) pendant le spin. Le robot a des conventions de signe MIROIR gauche/droite : une pose sy
src/mjlab_microduck/tasks/mdp.py:6099
Functionleg_joint_vel_l2
Penalize leg joint velocities to encourage smoother, less dynamic motion. Leg joints are indices 0-4 and 9-13 (10 joints total). Args:
src/mjlab_microduck/tasks/mdp.py:1433
Functionleg_symmetry_reward
Reward left/right legs mirroring — the swizzle's defining symmetry. The robot uses mirrored L/R sign conventions, so a bilaterally-symmetric conf
src/mjlab_microduck/tasks/mdp.py:4792
Methodlocal_to_world
(vec: np.ndarray)
src/mjlab_microduck/tasks/mdp.py:4552
Functionmaybe_set_random_prone_orientation
Reset event that overrides orientation to prone with probability `prone_prob`. With prob `prone_prob`, replaces the upright orientation (already
src/mjlab_microduck/tasks/mdp.py:4401
Functionmicroduck_vel_symmetry
Bilateral symmetry augmentation / mirror function for the microduck vel env. Returns [original, mirrored] concatenated along the batch dimension.
src/mjlab_microduck/tasks/symmetry.py:118
Functionmouth_ground_proximity
Reward for mouth tip approaching the ground, weighted by the approach phase. The command for the ground pick task is [cos(2π*phase), sin(2π*phase
src/mjlab_microduck/tasks/mdp.py:1838
Functionmouth_ground_proximity_phased
mouth_ground_proximity gaté par la down-gate segmentée (descente+palier).
src/mjlab_microduck/tasks/mdp.py:2987
← previousnext →301–400 of 681, ranked by callers