moveit_calibration icon indicating copy to clipboard operation
moveit_calibration copied to clipboard

Simulation environment

Open JStech opened this issue 4 years ago • 8 comments

A Gazebo simulation, with rendered images, would help for development and testing of this package. It'd also be helpful so we can provide a tutorial that doesn't depend on having hardware. I've started working on this, but I've not had a lot of time for it and I'm new to Gazebo, so it's slow going so far.

JStech avatar Aug 05 '20 04:08 JStech

@JStech I've been attempting to follow the tutorial in a gazebo simulation, I can't get an output pose, and I've run into several crashes while trying. Can you clarify specifically why hardware is required, and what needs changed to make this package work in simulation? Thanks

ros-gy avatar Aug 31 '20 18:08 ros-gy

I was able to run this in simulation, although I've not packaged it up and shared it. I used the simulation setup described in this tutorial, and created a target in Blender (a simple box textured with the target image). So hardware is not actually required, and I should update the tutorial to say hardware or a working Gazebo simulation is required. I'd planned to tidy things up but of course perfect is the enemy of done, so I should just throw it up somewhere.

What do you mean by "I can't get an output pose"? If you look at the target detection image, do the markers get outlined?

JStech avatar Sep 01 '20 04:09 JStech

Thanks for the reply. I did the same, i added a textured box with a target image. Yes, I am getting markers outlined from target detection. After 5 samples, the FOV marker array shows. If i hit the "save camera pose" the RVIZ interface locks up and I don't get an output file. I will dig into this some more.

ros-gy avatar Sep 01 '20 14:09 ros-gy

OK, I'll see if I can replicate this. Also, 5 poses is the bare minimum to calculate a calibration, but a few more will greatly improve it. I recommend doing ~12.

JStech avatar Sep 01 '20 14:09 JStech

I just did 9 poses, and when I hit the button, it looked like a new window was in focus. If i hover over the "RVIZ" icon, and empty window shows "Save camera pose" window. If i close this, then I get RVIZ back. But there is no visual window for me to see options. Should there be a popup window when I hit "Save camera pose?" image

ros-gy avatar Sep 01 '20 15:09 ros-gy

Yes, there should be. That's a bug I've run into before but hadn't had the chance to chase down until now. I think this fixes it, #24. Could you pull that branch and give it a try?

JStech avatar Sep 02 '20 22:09 JStech

Here is my quick-and-dirty simulation setup: https://github.com/JStech/moveit_cal_simulation

JStech avatar Sep 02 '20 22:09 JStech

Yes, there should be. That's a bug I've run into before but hadn't had the chance to chase down until now. I think this fixes it, #24. Could you pull that branch and give it a try?

Yes, PR 24 fixed it, I can now save the camera pose! Thank you.

Also, thank you for posting the simulation, I will take a look soon.

ros-gy avatar Sep 10 '20 02:09 ros-gy