ORB_SLAM installation on Ubuntu Xenial 16.04

2019-07-21 08:37发布

问题:

Is it possible to install ORB_SLAM/ORB_SLAM2 on last version of Ubuntu (Xenial 16.04) without black magic? I know that the recommendation is to use Ubuntu 14.04 according to https://github.com/raulmur/ORB_SLAM2, but I currently have last version and I don't really want to change it or install 14 together with 16. I use OpenCV 2.4.8 and ROS/catkin build system and get the next error:

/home/roman/ORB_SLAM2/src/Optimizer.cc:1244:1:   required from here
/usr/include/eigen3/Eigen/src/Core/util/StaticAssert.h:32:40: error: static assertion failed: YOU_MIXED_DIFFERENT_NUMERIC_TYPES__YOU_NEED_TO_USE_THE_CAST_METHOD_OF_MATRIXBASE_TO_CAST_NUMERIC_TYPES_EXPLICITLY

What's wrong with it? Thanks.

回答1:

I had this same issue, this is what worked for me.

Install eigen form here https://launchpad.net/ubuntu/trusty/amd64/libeigen3-dev/3.2.0-8

Download the .deb file and install using

sudo dpkg -i libeigen3-dev_3.2.0-8_all.deb


回答2:

wget "http://bitbucket.org/eigen/eigen/get/3.2.8.tar.gz"

tar zxvf 3.2.8.tar.gz

cd eigen*

/eigen-eigen-07105f7124f9$ mkdir build

/eigen-eigen-07105f7124f9$ cd build

/eigen-eigen-07105f7124f9/build$ cmake .. 

/eigen-eigen-07105f7124f9/build$ make

/eigen-eigen-07105f7124f9/build$ sudo make install

Hope this helps someone though its a delayed reply.