DanielTakeshi / deformable-ravens

Code for ICRA 2021 paper: https://arxiv.org/abs/2012.03385
Apache License 2.0
143 stars 30 forks source link

Using the 2-finger gripper? #7

Closed Abduoit closed 3 years ago

Abduoit commented 3 years ago

Thanks a lot for sharing the amazing work,

I can run the demo using self.ee = 'suction', but I failed to do it with Robotiq2F85.

I see this is the line where to load specific end-effector. For example, using insertion.py task, from here I changed it to self.ee = 'gripper'.

The gripper could be loaded but the robot doesn't move correctly to the target object, the end-effector always moves upside down. The robot seems to approach the object for picking but the gripper heads to the up direction.

When I run python main.py --disp --task insertion I get the following,

Traceback (most recent call last):
  File "main.py", line 251, in <module>
    demo_reward, episode, t, last_obs_info = rollout(task.oracle(env), env, task, args)
  File "main.py", line 114, in rollout
    (obs, reward, done, info) = env.step(act)
  File "/home/abdu/deformable-ravens/ravens/environment.py", line 268, in step
    success = self.primitives[act['primitive']](**act['params'])
  File "/home/abdu/deformable-ravens/ravens/environment.py", line 602, in pick_place
    while not self.ee.detect_contact(def_IDs) and target_pose[2] > 0:
TypeError: detect_contact() takes 1 positional argument but 2 were given
numActiveThreads = 0
stopping threads
Thread with taskId 0 exiting
Thread TERMINATED

When I print the pose0[0] and pose0[1] from here I get

Pose0[0] (0.359375, -0.21249999999999997, 0.040639832615852356)
Pose0[1] (0.0, 0.0, 0.0, 1.0)

Any help would be greatly appreciated... Thanks

DanielTakeshi commented 3 years ago

Hi @Abduoit thanks for the comment! none of the experiments or tasks I use require the Robotiq2F85. I never used that during this research, it was left over from code I built upon and is not expected to be functional.