Open peppegti opened 2 years ago
Have you tried downgrading to OpenCV version 3?
I am working on Ubuntu 20.04 and met some problems about OpenCV. So I turned to using Docker support provided in the repository, which is easy to deploy and runs well.
One probable reason is your version of OPENCV, vins-fusion is based on opencv3 while your opencv4 may not support some variable's name. Maybe you can try following steps:
Add some head files to these "error" files, according to my own experience:
In the head file in /camera_model, which is "Chessboard.h", add:
In "CameraCalibration.h", add:
In "loop_fusion/src/VRIEF.h", add:
In "loop_fusion/src/pose_graph.cpp", revise: CV_FONT_HERSHEY_SIMPLEX -> cv::FONT_HERSHEY_SIMPLEX
In "vins_estimator/src/feature_tracker.h", add:
In, "vins_estimator/src/KITTIOdomTest.cpp KITTIGPSTest.cpp", revise: CV_LOAD_IMAGE_GRAYSCALE -> cv::IMREAD_GRAYSCALE Above changes are to adapt VINS-FUSION to opencv4
https://github.com/rkuo2000/VINS-Fusion/ Fixes: CMakeFiles.txt: set(CMAKE_CXX_FLAGS "-std=c++14") camera_models/chessboard/Chessboard.cc: #include <opencv2/imgproc/types_c.h> camera_models/chessboard/Chessboard.cc: cv::CALIB_CB_ADAPTIVE_THRESH, cv::CALIB_CB_NORMALIZE_IMAGE, cv::CALIB_CB_FILTER_QUADS, cv::CALIB_CB_FAST_CHECK camera_models/src/intrinsic_calib.cc: #include <opencv2/imgproc/imgproc_c.h> camera_models/src/calib/CameraCalibration.cc: #include <opencv2/imgproc/types_c.h>, #include <opencv2/imgproc/imgproc_c.h> loop_fusion/src/ThirdParty/DVision/BRIEF.cpp: #include <opencv2/imgproc/types_c.h> loop_fusion/src/pose_graph.cpp: cv::FONT_HERSHEY_SIMPLEX loop_fusion/src/keyframe.cpp: cv::FONT_HERSHEY_SIMPLEX
This fork is adapted for OpenCV 4, Ceres 2.1. Tested with ROS Noetic, but it might work on Kinetic. Fork: https://github.com/guisoares9/VINS-Fusion
opencv version problem, you can revise the CMakeList.txt
in camera_models
;
if you installed both opencv 3 and 4, then find_package(OpenCV REQUIRED)
will probably find opencv 4, so you need to change it to OpenCV 3 REQUIRED
I guess
Here's my fork for OpenCV 4.2 (detail code modification are listed in the ReadMe.md) https://github.com/rkuo2000/VINS-Fusion/
I added Github Actions to automatically build Docker images of VINS-Fusion running on ROS Noetic, https://github.com/rosblox/ros-vins-fusion.
The Docker image can be pulled with
docker pull ghcr.io/rosblox/ros-vins-fusion:noetic
Maybe this helps running VINS-Fusion quickly.
Hello all, I try to use VINS-fusion in my workspace. This is my system setting: Ubuntu 20.04 + opencv_version 4.2.0 + gcc (Ubuntu 9.3.0-17ubuntu1 ~ 20.04) 9.3.0 I have two questions: 1- which version of Ceres Solver do you suggest 2.0.0 or 1.14.0? 2- at the moment I have 1.14, but yesterday I tried to install ceres solver 2.0.0. Both versions give me some errors during the catkin_make. How can these problems be solved?