You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are the following inconsistencies between the formula and the code:
The directions of the position error and velocity error are opposite.
In the documentation: $(q - q_{des}),(\dot{q} - \dot{q}_{des})$
In the code:
$(q_{des} - q),(\dot{q}_{des} - \dot{q})$
This inconsistency may lead to misunderstandings or incorrect controller behavior. I would like to clarify the following points:
Is there a unified definition of the error direction in both the formula and the code?
If the code implementation is correct, should the formula in the documentation be revised to $(q_{des} - q)$ and $(\dot{q}_{des} - \dot{q})$?
If the formula in the documentation is correct, should the code be modified to match the formula?
Looking forward to your response. Thank you!
System Info
Describe the characteristic of your environment:
Commit: [8f3b9ca]
Isaac Sim Version: [4.2.0]
OS: [Ubuntu 20.04]
GPU: [RTX 4070 Ti Super]
CUDA: [12.2]
GPU Driver: [535.171.04]
The text was updated successfully, but these errors were encountered:
defcompute(
self, control_action: ArticulationActions, joint_pos: torch.Tensor, joint_vel: torch.Tensor
) ->ArticulationActions:
# compute errorserror_pos=control_action.joint_positions-joint_poserror_vel=control_action.joint_velocities-joint_vel# calculate the desired joint torquesself.computed_effort=self.stiffness*error_pos+self.damping*error_vel+control_action.joint_efforts# clip the torques based on the motor limitsself.applied_effort=self._clip_effort(self.computed_effort)
# set the computed actions back into the control actioncontrol_action.joint_efforts=self.applied_effortcontrol_action.joint_positions=Nonecontrol_action.joint_velocities=Nonereturncontrol_action
Parameters:
control_action – The joint action instance comprising of the desired joint positions, joint velocities and (feed-forward) joint efforts.
joint_pos – The current joint positions of the joints in the group. Shape is (num_envs, num_joints).
joint_vel – The current joint velocities of the joints in the group. Shape is (num_envs, num_joints).
Describe the bug
"The torque calculation formula in the documentation is inconsistent with the actual code implementation, which may cause confusion or errors."
Error details
In the documentation, the formula for calculating torque is:
Whereas in the code implementation:
There are the following inconsistencies between the formula and the code:
The directions of the position error and velocity error are opposite.
$(q - q_{des}),(\dot{q} - \dot{q}_{des})$
In the documentation:
In the code:
This inconsistency may lead to misunderstandings or incorrect controller behavior. I would like to clarify the following points:
Is there a unified definition of the error direction in both the formula and the code?$(q_{des} - q)$ and $(\dot{q}_{des} - \dot{q})$ ?
If the code implementation is correct, should the formula in the documentation be revised to
If the formula in the documentation is correct, should the code be modified to match the formula?
Looking forward to your response. Thank you!
System Info
Describe the characteristic of your environment:
The text was updated successfully, but these errors were encountered: