Problem with the reference frame of grasps in the household_objects_database
I'm using the manipulation stack in ROS electric, in a simulated environment in Gazebo. I have a simulated robot arm and hand, a simulated table and a coke can, and a simulated kinect.
Object recognition is working well with the coke can, from the model in the household_objects_database (using the image from the simulated kinect).
But the problem is that when I want to use the object_manipulator, the grasps for that object are read from the database and represented in a weird and unexpected way.
The grasps (and pregrasps) for the coke can are in the grasp table of the DB with different positions but all of them have the identity quaternion (0,0,0,1) for orientation, so no rotation should be applied. But when trying to pickup the object with object_manipulator, the grasps are read from the database and the markers representing the grasps are more or less (but not exactly) in the expected position, but they have a completely unexpected orientation, as it can be seen in the following two images.
I thought that the parent frame of the grasps would be the frame of the recognised object (/object_frame in this case), but the orientation of the represented grasps is different from that.
Can anyone tell me what's the reference frame of the grasps, or what can I be doing wrong?