Open shayan-ahmadi9 opened 3 months ago
You can try turning off use_delta and set normalize_action False and interpolate false. if you keep taking a lot of the same action / target ee pose, it should eventually reach it
@shayan-ahmadi9 has your issue been resolved?
Thank you for your help!
I applied the recommended changes with the following configuration:
frame = base
use_delta = False
normalize_action = False
interpolate = False
use_target = False
I also adjusted the main control loop as follows:
# Control loop to move towards the target pose
pos_error, rot_error = np.inf, np.inf
while (pos_error > threshold_pos) or (rot_error > threshold_rot):
# Convert Quaternion to Euler
target_rot_euler = Rotation.from_quat(target_rot_quat).as_euler('xyz')
# Create the action vector with the gripper action set to 0.9 (open)
action = np.concatenate((target_pos, target_rot_euler, np.array([0.9])), axis=0)
# Take a step in the environment
state = env.step(action)
# Update the current pose from the new state
current_pose_robot_frame = robot_pose * env.agent.robot.get_links()[-3].get_pose()
current_pos = current_pose_robot_frame.p
current_rot_quat = current_pose_robot_frame.q
# Calculate errors
pos_error = np.linalg.norm(current_pos - target_pos)
rot_error = np.linalg.norm(quaternion_to_gripper_shortest_euler(current_rot_quat, target_rot_quat))
env.render()
The robot’s behavior has changed slightly, but it still struggles to reach the desired rotation. The issue persists, especially with achieving accurate orientation.
Any further suggestions or insights would be greatly appreciated!
Thanks again for your time and help.
I find use delta pose as action for EE mode in maniskill, can adjust the rotation nearly to the target one.
Hello,
I'm currently working with the PickCube-v0 environment in ManiSkill2 (version 0.5.3) using the pd_ee_delta_pose control mode on Ubuntu 22.04.4 LTS. While the robot successfully reaches the desired position when controlling only the position, it struggles to achieve the correct orientation (rotation) when attempting to control the full pose. The issue is particularly evident when controlling both position and orientation (or even just orientation), as the robot fails to reach the target pose/rotation for most seeds other than env.reset(seed=1).
I'm using the following PDEEPoseControllerConfig settings:
frame = base use_delta = True normalize_action = True interpolate = True use_target = False
Could you please provide guidance on what might be going wrong with the orientation control and how I can effectively control the robot to achieve a specific target pose? Any suggestions or corrections would be greatly appreciated.
Thank you for your time and assistance!