Skip to content

Instantly share code, notes, and snippets.

@hansen1416
Created October 9, 2023 05:18
Show Gist options
  • Save hansen1416/0374244a1bb0a1ca4afbc8ee27db1d64 to your computer and use it in GitHub Desktop.
Save hansen1416/0374244a1bb0a1ca4afbc8ee27db1d64 to your computer and use it in GitHub Desktop.
"""
`dynprm` is a vector of actuator dynamic parameters that includes the actuator’s mass, damping, and spring constant 1.
`gainprm` is a vector of actuator gain parameters that includes the actuator’s proportional gain, derivative gain, and integral gain 1.
`biasprm` is a vector of actuator bias parameters that includes the actuator’s bias force and bias torque
"""
model = mujoco.MjModel.from_xml_path(xml_path)
data = mujoco.MjData(model)
data.ctrl[_actuator_index_] = 0.61826
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment