ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Why import my own cad file is more slow than import PR2 cad model?

asked 2011-08-02 20:53:05 -0600

sam gravatar image

updated 2014-01-28 17:10:08 -0600

ngrennan gravatar image

I tried to covert my own cad file to stl file. And I use the command to import

  rosrun gazebo spawn_model -file foot.urdf -urdf -model top -z 0.5

I have waited several minutes but do not see any progress or message.

Why it be so slow? And how do I speed up?

Thank you~

edit retag flag offensive close merge delete

Comments

Please upload your URDF and STL files somewhere.
Martin Günther gravatar image Martin Günther  ( 2011-08-05 02:50:04 -0600 )edit

2 Answers

Sort by » oldest newest most voted
1

answered 2011-08-09 18:45:01 -0600

sam gravatar image

updated 2011-08-09 19:29:37 -0600

I have tried to reduce the resolution of my stl file. I found 3 ways to do it,and I only try the third.

1.Use SOLIDCast to reduce the triangle number.

http://www.cast-cae.com/forum.php?mod=viewthread&tid=385

2.Use 3ds Max to reduce the vertex.

http://www.ddove.com/3dmax/sl/tut_using_the_vertex_weld_modifier.html

3.Use Inventor to export stl file with options.

It can be choice : high,medium,low,custom

What I found is if I try to import the same motor stl with different resolution successfully,

 load motor_lowest.stl(296k,about 0 sec)
 load motor_low.stl(512k,about 0 sec)
 load motor_medium.stl(1028k,about 3 sec)
 load motor_high.stl(2820k,about 10 sec)
 load motor_highest.stl(51M, very very long)
edit flag offensive delete link more
0

answered 2011-08-05 07:47:23 -0600

hsu gravatar image

One possibility is that you have simply too many vertices/faces in your mesh. PR2 URDF has been simplified to around 1k faces per STL/DAE component, the original PR2 CAD file had about 300X that number of faces/vertices straight out of Solidworks. Try keeping the total number of faces of your robot mesh (collision and visual) to less than 50k should correlate to loading time of under a second. I don't have an exact number, maybe your data point could shed some light on that topic and potentially identify bottlenecks for model loading if it's pertinent to your work?

edit flag offensive delete link more

Comments

Yeah,I found that that stl file is more bigger(36MB) than others. I successfully import another 6-axis arm (3MB)in gazebo. I will try to shed some parts to find bottle neck in the future.What the problem I met is how to combine many parts into one inseparable to reduce the total component number?
sam gravatar image sam  ( 2011-08-09 00:48:53 -0600 )edit
You'll need a separate mesh editor to simplify your model (e.g. shrink wrap with your cad software and decimate vertices). A lot of manual work involved depending on the level of detail you would like to achieve in your model. If you find something automatic, please share with us. Thanks.
hsu gravatar image hsu  ( 2011-08-09 13:13:47 -0600 )edit

Question Tools

Stats

Asked: 2011-08-02 20:53:05 -0600

Seen: 710 times

Last updated: Aug 09 '11