git clone git://github.com/UZ-SLAMLab/ORB_SLAM3.git
将/src/Localmapping.cc中628行、/src/CameraModels/KannalaBrandt8.cpp534行x3D = x3D_h.get_minor<3,1>(0,0) / x3D_h(3); 改为x3D = cv::Matx31f(x3D_h.get_minor<3,1>(0,0)(0) / x3D_h(3), x3D_h.get_minor<3,1>(0,0)(1) / x3D_h(3), x3D_h.get_minor<3,1>(0,0)(2) / x3D_h(3));
cd ORB_SLAM3/
chmod +x build.sh
./build.sh
打开~/.bashrc,在最后一行添加
export ROS_PACKAGE_PATH=${ROS_PACKAGE_PATH}:/YourPath/ORB_SLAM3/Examples/ROS
修改/Examples/ROS/ORB_SLAM3的33行find_package(OpenCV 3.0 QUIET) 改为set(OpenCV_DIR /Your_path_to_opencv/build) find_package(OpenCV QUIET)
source ~/.bashrc
chmod +x build_ros.sh
./build_ros.sh
Running Stereo-Inertial Node robotics.ethz.ch/~asl-datasets/ijrr_euroc_mav_dataset/vicon_room1/V1_01_easy/V1_01_easy.bag
roscore
rosrun ORB_SLAM3 Stereo_Inertial Vocabulary/ORBvoc.txt Examples/Stereo-Inertial/EuRoC.yaml true
rosbag play --pause V1_01_easy.bag /cam0/image_raw:=/camera/left/image_raw /cam1/image_raw:=/camera/right/image_raw /imu0:=/imu
Running RGB_D Node
./Examples/RGB-D/rgbd_tum ./Vocabulary/ORBvoc.txt ./Examples/RGB-D/TUM1.yaml ./Examples/rgbd_dataset_freiburg1_xyz/ ./Examples/RGB-D/associations/fr1_xyz.txt
|