spencer-project / spencer_people_tracking

Multi-modal ROS-based people detection and tracking framework for mobile robots developed within the context of the EU FP7 project SPENCER.
http://www.spencer.eu/
660 stars 327 forks source link

Try to compile package on ubunto 16.04 ROS kinetic #21

Closed miguelmartins51 closed 7 years ago

miguelmartins51 commented 7 years ago

HI guys.

I am a beginner with ros and i found this project super interesting. I really want to try it with the kinect v1. Has anyone tried to compile this project on ubunto 16.04 with ros kinetic? error.docx

I am having this issues when i make my catkin_make. Anyone knows how to solve it ?

fatal error: pluginlib/class_list_macros.h: No such file or directory .... fatal error: nodelet/nodelet.h: No such file or directory .... fatal error: .......

It is like is not recognizing any of this libraries.

kotaweav commented 7 years ago

Please see the kinect-dev branch in joao-avelino's fork: https://github.com/joao-avelino/spencer_people_tracking/tree/kinetic_dev

Also, https://github.com/spencer-project/spencer_people_tracking/issues/19 and https://github.com/spencer-project/spencer_people_tracking/issues/20 should be of interest to you.

Just a note, a .docx isn't the right way to send an error log. Just put it in a plain text file, or better yet, use the code format using backticks (not quotes)

``` like this ```

which should appear

like this
tlind commented 7 years ago

Thanks @femtogram for mentioning joao-avelino's fork, it contains several fixes to make the framework work on 16.04 and ROS Kinetic. Most issues arise from the fact that ROS Kinetic per default ships with OpenCV3, which had some breaking API changes. There were also some package dependencies missing and include directories not being referenced. Not sure why those issues didn't appear in 14.04.

I'll see if we can merge joao-avelino's changes back into this repo at some point, if he agrees to that, and everything still works under 14.04/Indigo.

kotaweav commented 7 years ago

@tlind well, seems like most of joao-avelino's changes were around rviz's switch to Qt5 from Qt4 (which would break compatibility with 14.04 and Indigo, though joao-avelino's patch seems to account for that), and to address the issues with moc's C++ and preprocessor macro parsing, though he does indeed force building with OpenCV2 instead of 3 :) Looks like his changes aren't under a different license, so it should be safe to just merge his branch back in even without his explicit permission. GitHub allows you to do a pull request even if you aren't the owner of the fork: selection_038

ROS versions really are a pain aren't they XD I really wish the docker instances had better networking support... Or better yet if ROS supported more than just the single OS and version. It would really simplify things.

tlind commented 7 years ago

I contacted the author and he agreed for the changes to be merged back into our repository under the same license. I have subsequently merged PR #23 into master. I tested it under Ubuntu 14.04 / ROS Indigo and tracking_single_rgbd_sensor.launch works fine. Next, need to do further testing under 16.04 / ROS Kinetic as well as with the full SPENCER sensor setup.

Also still need to add an AUTHORS file and mention Joao for his great contribution.

tlind commented 7 years ago

Status update: Full sensor setup confirmed to be working under 14.04. Not yet tested under 16.04.

miguelcrf450 commented 7 years ago

HI,

Thank you guys for your help. Like someone said before "ROS versions really are a pain". I tested with 14.04 and ros indigo and everything seems working well. I followed the tips from @femtogram and used the freenect with kinect v1. Now i will see how this work with 16.06 and kinetic.

gregoirefra commented 7 years ago

For information, I tried it out on 16.04 with ROS Kinetic and there is a fail on build because of the hardcoded openCV 2. I'm trying to replace it with OpenCV 3 now but it seem's to be a really big task for the little knowledge I have on the difference between the two.

kotaweav commented 7 years ago

@gregoirefra OpenCV 3 is not backwards compatible with OpenCV 2. Honestly, you'll be better off just installing OpenCV 2. If I recall the CMakeLists.txt specifies a find_package(OpenCV 2) so you'll be best off just installing OpenCV 2 systemwide. You can install 2.4.9 via sudo apt install libopencv-dev. I think a port to 3 doesn't make sense at this point since ROS Jade and Ubuntu 14.04 don't support OpenCV 3, and since you can have both 2 and 3 on the same system.

@tlind perhaps the README should mention this dependency for Kinetic.

tlind commented 7 years ago

Which package is failing and what's the error message?

I fully agree with @femtogram, porting the code to OpenCV 3 doesn't make sense. It should be no problem to install OpenCV2 (via apt-get) in parallel to the OpenCV 3 installation that comes with ROS Kinetic, as the former resides in /usr/lib and the latter resides in /opt/ros. I don't know, though, what happens if you have already installed OpenCV3 system-wide.

tlind commented 7 years ago

@femtogram I have updated the README as you suggested. Still need to check (e.g. in a Docker container) if the listed dependencies for ROS Kinetic are 100% correct.

We should also add libopencv-dev as a build dependency to package.xml (this is currently not the case for the laser detectors and PCL people detector), and could then advise people to use rosdep to install the dependencies, as documented in #29.

tlind commented 7 years ago

Done in 4afe68c and tested under ROS Kinetic.