HorizonRobotics / SocialRobot

Apache License 2.0
71 stars 20 forks source link

cannot import name 'pygazebo' #136

Closed www2171668 closed 2 years ago

www2171668 commented 2 years ago

Hello, I meet a problem when i test "python3 python/social_bot/envs/play_ground.py". It shows: Traceback (most recent call last): File "python/social_bot/envs/play_ground.py", line 31, in import social_bot File "/home/huang/Project/HIDIO/SocialRobot/python/social_bot/init.py", line 66, in from . import pygazebo ImportError: cannot import name 'pygazebo'

I think I install correctly Gazebo9.19.0 and SocialRobot. My system is Ubuntu 18.04. Package is python3.6. I don't know how to choose Gazebo9.6 version, Is it influence the code? Thankyou.

www2171668 commented 2 years ago

I deal with it. When I put the pkg in a Root Pro(Root folder), It works well. But when I put them in a subfolder, it cant work. I think the position influences the code.

I also doublt the problem comes from the cmake. I delete the former "build" folder and cmake again. It becomes well. Maybe I firstly create cmake in python3.7 env. However, it warns that I should use python3.6. So, I adjust env. In that situation, we must delete the former "build".