Re: [ros-users] Python node design.

Top Page
Attachments:
Message as email
+ (text/plain)
+ (text/html)
Delete this message
Reply to this message
Author: User discussions
Date:  
To: ros-users
Subject: Re: [ros-users] Python node design.

hi Ken,

As with Blaise email, I comment on your comments.
> From:
> Date: Tue, 2 Nov 2010 09:31:02 -0700
> To:
> Subject: Re: [ros-users] Python node design.
>
> Hi Renato,
>
> I'm not sure I understand the problem, but have you tried:
>
> a) Sticking the .so files in the 'lib' directory of your package


When I try to put all .so files in LIB file, it still was not working
even including libraries flags in manifest.xml or a pyopencv.pc file
located in /lib/pkgconfig.

> b) If (a) is not possible, setting the <export> for Python in your
> manifest to point to the relevant location:
>
> http://www.ros.org/wiki/Manifest/XML#export:_.3Cpython.3E_tag

Unfortunately it has the same behaviour as when .py and .so files are located in src/.
>
> You could also look at the opencv2 package and see how it exports the
> Python bindings correctly (note: it had a bug, so you should check the
> most recent release).
>


I will try a better look on opencv2, I was also thinking to install these libraries in dist-packages/ site-packages/ from the python in ROS.

Regards,

Renato.
> - Ken
>
> 2010/11/2 Renato Samperio <>:
> > Dar ROS users,
> >
> > I would like to know if somebody could have a hint for our problem. This
> > question is for system design in python.
> >
> > We require of a ROS package holding a library for our system that has
> > relevant python wrappers (pyopencv) used in our system.
> >
> > So far, we have encapsulated all required libraries (*.so) and python files
> > (*.py) into a node structure which can be used by pointing it to the
> > LD_LIBRARY_PATH. However, if we want to run our system as a ROS node, we
> > also require to update this system variable.
> >
> > The 'manifest.xml' file for our ROS library (pyopencv) is:
> >
> > <package>
> >
> > <description brief="pyopencv"> pyopencv </description>
> >
> > <author>Renato Samperio</author>
> >
> > <license>BSD</license>
> >
> > <review status="unreviewed" notes=""/>
> >
> > <url>http://ros.org/wiki/pyopencv</url>
> >
> > <depend package="rospy"/>
> >
> > <depend package="sensor_msgs"/>
> >
> > <export>
> >
> > <cpp lflags="-Wl,-rpath,${prefix}/lib -L${prefix}/lib -lpyopencv_extras
> > -lboost_python -lcvaux -lcv_h_ext -lcv_hpp_ext -lcxcore_h_ext
> > -lcxcore_hpp_ext -lcxcore_hpp_point_ext -lcxcore_hpp_vec_ext -lcxtypes_h_ext
> > -lhighgui_ext -lcvaux -lcv -lcxcore -lhighgui -lml -lml_ext -lsdopencv_ext"
> > />
> >
> > </export>
> >
> > </package>
> >
> > We made our node following rules from PyStyleGuide. Our file system
> > structure is:
> >
> > pyopencv
> >
> > |- CMakeLists.txt
> >
> > |- manifest.xml
> >
> > |- mainpage.dox
> >
> > |- src/
> >
> > |- pyopencv/ ← Pointed to LD_LIBRARY_PATH
> >
> > |- __init__.py
> >
> > |- *.so, *.py, *.pyc
> >
> > I would really appreciate if somebody has an idea of how we could avoid the
> > LD_LIBRARY_PATH system variable.
> >
> > With best wishes,
> >
> > Renato Samperio
> >
> > _______________________________________________
> > ros-users mailing list
> >
> > https://code.ros.org/mailman/listinfo/ros-users
> >
> >
> _______________________________________________
> ros-users mailing list
>
> https://code.ros.org/mailman/listinfo/ros-users