Closed AndrewJSchoen closed 4 years ago
Hello, I've re-reported the bug upstream: https://bugs.gentoo.org/708184
Meanwhile it gets fixed, I've answered in another issue a workaround you can do to keep working: https://github.com/softbankrobotics-research/sbre_robot_ros_gentoo_prefix/issues/2
I hope it helps.
You can find some ready-to-use already built images here: https://github.com/awesomebytes/sbre_robot_ros_gentoo_prefix/releases They come from this discussion: https://github.com/softbankrobotics-research/sbre_robot_ros_gentoo_prefix/issues/4
@awesomebytes This is quite helpful, thanks.
Do you have any guidance on installing the qi-python bindings? I was able to get the libqi/libqicore built following the instructions on one of the pages (with the patches) on this release.
However, if I try to install the qi
python bindings (python -m pip install qi
), it installs, but trying to import results in a segmentation fault:
Python 2.7.17 (default, Mar 11 2020, 01:41:32)
[GCC 9.2.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import faulthandler
>>> faulthandler.enable()
>>> import qi
Fatal Python error: Segmentation fault
Current thread 0xb722f700 <python> (most recent call first):
File "/tmp/gentoo/usr/lib/python2.7/ctypes/__init__.py", line 366 in __init__
File "/tmp/gentoo/usr/lib/python2.7/ctypes/__init__.py", line 444 in LoadLibrary
File "/tmp/gentoo/usr/lib/python2.7/site-packages/qi/__init__.py", line 55 in <module>
File "<stdin>", line 1 in <module>
Segmentation fault
I imagine this has something to do with the bindings not finding the correct binaries, but I am not sure. Have you had any luck with this?
EDIT:
I ended up looking into the /tmp/gentoo/usr/lib/python2.7/site-packages/qi/__init__.py
file. They import a series of shared objects, beginning with libc.so.6
from /data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/libc.so.6
. Importing this seems to throw the seg fault. I tried replacing this file with the one from /lib/libc.so.6, and this seg faults as well. Commenting out that import allows things to proceed successfully for the following imports:
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/libstdc++.so.6
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/ld-linux.so.2
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/librt.so.1
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/libm.so.6
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/libdl.so.2
/data/home/nao/gentoo/usr/lib/python2.7/site-packages/qi/robot/libgcc_s.so.1
...but eventually errors out at importing libssl.so.1.0.0
Hey @AndrewJSchoen I just commented in: https://github.com/softbankrobotics-research/sbre_robot_ros_gentoo_prefix/issues/2 that I expected something like that to happen. There may be something interesting for you in what I wrote already.
I've never installed qi
from pip. By what I see, in qi in PyPI it's version 1.7.2 which sounds like very outdated***. The last one (for NaoV6, dunno if you are using that one, but I'm assuming so for now) is 2.8.6.23 as found in NaoV6 Downloads.
For my pepper_os image I just extract the qi Python library somewhere. And I add to my PYTHONPATH in my .bash_profile
: https://github.com/awesomebytes/pepper_os/blob/master/config/.bash_profile#L10 that somewhere.
I also needed to edit a __init__.py
file for some reason I don't remember, something crashed probably: https://github.com/awesomebytes/pepper_os/blob/master/Dockerfile#L287
If this becomes necessary for everyone (oh, and also, if it works), I'll propose to add that to the Dockerfiles so users don't need to fight it.
***Edit: I just saw in the release history it's actually very recent. Oh well, that was wrong, my bad. I can only say to try to install it in .local by doing pip install --user qi
and see if that maybe helps (it shouldn't).
@awesomebytes I can try the user install. I think I tried that at some point, but will let you know in any case. If it fails, I can look into the extracted version. For what it is worth, I am currently trying to install on the pepper (2.5.X
), but we also have some NAOv4's that use 2.1.X
that it may eventually be useful to get working with this type of setup.
Thanks for all the help!
@AndrewJSchoen If it's for Pepper, you may want to take a look into https://github.com/awesomebytes/pepper_os instead. It does come with A LOT of stuff that you may find useful (ok, maybe too much? but that's just some disk space lost). Just make sure to read the warning in the README about deploying it in your robot. I can assure you that it works (at least with Kinetic) as our robots work with it. I haven't done a deployment from scratch in a while... but nothing major has changed in months. That image includes ROS navigation, ROS perception, Tensorflow, teb_local_planner, dlib... well a lot of stuff. It's listed in the README. Now that I think about it, I think I didn't update it with naoqi_driver, but I can try to add it when I have a bit of time from the work I did in this repo.
Btw this may work on the NaoV4 out of the box... but having a single core Atom 1.6GHz with 1GB RAM and limited disk space... You won't be able to run much on it.
@awesomebytes Thanks for all the help. I did end up going the pepper_os route, and things worked great.
I was attempting to run the
ros_kinetic_32
branch instructions on a 32-bit Ubuntu install (18.04), but I get the following error during stage 3:Any suggestions on what might be the issue?