Ask Your Question
0

Cannot add mesh files to moveit!

asked 2019-02-23 04:55:55 -0500

ArunPrasanth gravatar image

I'm trying to add the mesh files to moveit! in ROS kinetic for baxter robot. I'm using python code to implement it. I used this below function to add the mesh file
scene.add_mesh("pin",pin_pose,resourcepath '/objects/Pin.stl')

And I have also used scene.add_box("box", box_pose, (0.001, 0.001, 0.05))

for adding the small box. My problem is,the box is added,but the mesh file is not. I'm getting segmentation fault(core dumped) error, when it tries to execute the addmesh line. I have tried with different .stl files and also with .dae files. At the same time, I can import this same .stl file directly in moveit!. I don't know what is the reason for the segfault. Can someone help to resolve this error?

ROS_ROOT=/opt/ros/kinetic/share/ros ROS_PACKAGE_PATH=/opt/ros/kinetic/share ROS_MASTER_URI=http://localhost:11311 ROS_VERSION=1 ROSLISP_PACKAGE_DIRECTORIES= ROS_DISTRO=kinetic ROS_ETC_DIR=/opt/ros/kinetic/etc/ros

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2019-03-22 04:30:29 -0500

YX.Z gravatar image

I'm working on this those days, and I do find one way to fix this problem. This is maybe a pyassimp bug, check out if you're using pyassimp 4.1.4 or not. If so, use sudo -H pip uninstall pyassimp and sudo -H pip install pyassimp==4.1.3 or 3.3 is ok. I tried this, and my mesh import works well. Hope this answer may be helpful

edit flag offensive delete link more

Comments

Hi, Thank you so much for your reply. I was aware of this issue https://github.com/ros-planning/movei... before working with moveit! and I installed necessary pyassimp and I already have version 4.1.3. I checked it by opening editor, used import moveit_commander, it works. The error is when I use the command scene.add_mesh(). I tried giving both absolute path and relative path. Now I'm stuck with moving forward.

ArunPrasanth gravatar imageArunPrasanth ( 2019-03-22 10:26:32 -0500 )edit

Yes,I am aware of this issues too, whereas the link we know both, gives us a way to install a new pyassimp to replace the version pyassimp 3.2 which are attached to ros-kinetic-full. However, if you do as sudo pip intall pyassimp you'll get pyassimp 4.1.4 rather than pyassimp 4.1.3. So make sure you are not using 4.1.4. When I use 4.1.4,I have segmentation fault(core dumped) error, but none with pyassimp 4.1.3 or pyassimp 3.3. This is all I get for this issue, if you do use a 4.1.3 version, then I do recommend you to open a issue in its github issues page.

YX.Z gravatar imageYX.Z ( 2019-03-24 01:40:51 -0500 )edit

Hi Again, I'm using different PC and checked that I'm using pyassimp 4.1.4. I tried to install the version you said and I get **Collecting pyassimp==4.1.3 Installing collected packages: pyassimp Found existing installation: pyassimp 4.1.4 Cannot uninstall 'pyassimp'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.


It seems the pyassimp is broken or I do not know the exact solution. Now I neither can't uninstall or reinstall the version you said. Any help would be appreciated.

Thank you in advance.

ArunPrasanth gravatar imageArunPrasanth ( 2019-04-02 10:00:36 -0500 )edit

I met this phenomena once, then I tried this sudo dpkg --remove --force-depends python-pyassimp,then sudo -H pip install pyassimp==4.1.3. It works for me.

YX.Z gravatar imageYX.Z ( 2019-04-03 01:44:28 -0500 )edit

Hi, Thanks again, I tried sudo dpkg --remove --force-depends python-pyassimp and then sudo -H pip install pyassimp==4.1.3 as you said. I'm getting the same error, **/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/__init__.py:83: RequestsDependencyWarning: Old version of cryptography ([1, 2, 3]) may cause slowdown. warnings.warn(warning, RequestsDependencyWarning) DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. Collecting pyassimp==4.1.3 Installing collected packages: pyassimp Found existing installation: pyassimp 4.1.4 Cannot uninstall 'pyassimp'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.


I assume that, I installed many number of ...(more)

ArunPrasanth gravatar imageArunPrasanth ( 2019-04-03 05:04:28 -0500 )edit

Well, I guess this issue may help.

YX.Z gravatar imageYX.Z ( 2019-04-03 08:36:39 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2019-02-23 04:55:55 -0500

Seen: 287 times

Last updated: Feb 23