andyzeng / visual-pushing-grasping

Train robotic agents to learn to plan pushing and grasping actions for manipulation with deep reinforcement learning.
http://vpg.cs.princeton.edu/
BSD 2-Clause "Simplified" License
883 stars 314 forks source link

Calculation of tool_rotation_angle in robot.py #48

Open taeil7kim opened 4 years ago

taeil7kim commented 4 years ago

Hi, I found that the tool_rotation_angle is calculated in different ways for the simulation case and the real case in grasp() and push() functions of robot.py. In robot.py,

(simulation case) Line 601: tool_rotation_angle = (heightmap_rotation_angle % np.pi) - np.pi/2

(real case) Line 662: tool_rotation_angle = heightmap_rotation_angle/2

I can understand the line 601 that rotates the tool 90 degrees from the heightmap_rotation_angle . Could you explain why the heightmap_rotation_angle is divided by 2 in line 662?