omrirz / pyrosenv Goto Github PK
View Code? Open in Web Editor NEWSet an environment for easy work with ROS in python without setting things up
License: MIT License
Set an environment for easy work with ROS in python without setting things up
License: MIT License
Thank you for this awesome package. It does not seem like cv_bridge works with pyrosenv.
I am importing it as from pyrosenv.cv_bridge import CvBridge
and receiving an error saying: ModuleNotFoundError: No module named 'pyrosenv.cv_bridge'
. It is possible I am just not importing it correctly.
If this has not yet been implemented, are there any plans to? I am sure there are others that would like to see support for cv_bridge too.
Thanks!
@omrirz Thanks for adding cv_bridge to your package! Since your code is meant to be run with Python 3, I am running into an issue with using cv_bridge. Here is the error that I am receiving:
frame_0 = bridge.imgmsg_to_cv2(msg, desired_encoding = "passthrough") # Save off frame as cv_image
File "visualize_img.py", line 67, in visualizeImage
frame_0 = bridge.imgmsg_to_cv2(msg, desired_encoding = "passthrough") # Save off frame as cv_image
File "/opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py", line 163, in imgmsg_to_cv2
dtype, n_channels = self.encoding_to_dtype_with_channels(img_msg.encoding)
File "/opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py", line 99, in encoding_to_dtype_with_channels
return self.cvtype2_to_dtype_with_channels(self.encoding_to_cvtype2(encoding))
File "/opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py", line 91, in encoding_to_cvtype2
from cv_bridge.boost.cv_bridge_boost import getCvType
ImportError: dynamic module does not define module export function (PyInit_cv_bridge_boost)
I'm unsure whether it is an issue on my end or with the package. I am pretty sure cv_bridge is just being built with python 2.7 instead of python 3 causing the issue. Let me know if you have any suggestions. Thanks again!
Great Idea to collect all ros dependencies! I'm having trouble finding the relevant packages for reading rosbags in python3 and this will hopefully solve it all.
"no module named rospy", "no module named std_msgs" is the problem, though no error in installation phase.
...
Installing collected packages: more-itertools, attrs, iniconfig, py, toml, pluggy, pyparsing, six, packaging, pytest, pyros-config, pyros-setup, psutil, gnupg, defusedxml, pycrypto, PyYAML, distro, docutils, python-dateutil, catkin-pkg, rospkg, pyrosenv
Successfully installed PyYAML-5.3.1 attrs-20.1.0 catkin-pkg-0.4.22 defusedxml-0.6.0 distro-1.5.0 docutils-0.16 gnupg-2.3.1 iniconfig-1.0.1 more-itertools-8.5.0 packaging-20.4 pluggy-0.13.1 psutil-5.7.2 py-1.9.0 pycrypto-2.6.1 pyparsing-2.4.7 pyros-config-0.2.1 pyros-setup-0.3.0 pyrosenv-0.0.4 pytest-6.0.1 python-dateutil-2.8.1 rospkg-1.2.8 six-1.15.0 toml-0.10.1
(baghandler) [pli@zenbook ~]$ python
Python 3.8.5 (default, Aug 12 2020, 00:00:00)
[GCC 10.2.1 20200723 (Red Hat 10.2.1-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
import pyrosenv
Traceback (most recent call last):
File "/home/pli/baghandler/lib/python3.8/site-packages/pyrosenv/init.py", line 30, in
import rospy
ModuleNotFoundError: No module named 'rospy'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/pli/baghandler/lib/python3.8/site-packages/pyrosenv/init.py", line 42, in
import rospy
ModuleNotFoundError: No module named 'rospy'
During handling of the above exception, another exception occurred:
following https://answers.ros.org/question/343260/install-of-the-rospyrosbag-python-libraries-standalone-not-on-ubuntu/
I could install the packages I needed.
I run "pip install pyparsing" and get: "Requirement already satisfied: pyparsing in c:\programdata\anaconda3\lib\site-packages (2.4.7)"
but when running python it failed, what can I do?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.