dvorak0 / VI-MEAN

Visual-Inertia-fusion-based Monocular dEnse mAppiNg
GNU General Public License v3.0
208 stars 147 forks source link

Dependency versions? #4

Open andyli opened 7 years ago

andyli commented 7 years ago

I'm trying to compile the project, but got several compilation errors. I'm using ROS Kinetic, and got errors about OpenCV, which is of version 3.2 in ROS Kinetic. Maybe this project was developed in another release of ROS or OpenCV?

It would be great if you can clarify.

dvorak0 commented 7 years ago

The code is only tested under indigo.

jakeware commented 7 years ago

Would you mind providing the OpenCV version and build options you used? It seems like cuda is required and is not built by default or mentioned in your build documentation. For reference, I have tried the following opencv build options with 14.04, ROS indigo, and OpenCV 2.4.13:

cmake -G "Unix Makefiles" -DCMAKE_CXX_COMPILER=/usr/bin/g++ CMAKE_C_COMPILER=/usr/bin/gcc -DCMAKE_BUILD_TYPE=RELEASE -DCMAKE_INSTALL_PREFIX=/home/jakeware/opencv2 -DWITH_TBB=ON -DBUILD_NEW_PYTHON_SUPPORT=ON -DWITH_V4L=ON -DWITH_QT=OFF -DWITH_OPENGL=ON -DBUILD_FAT_JAVA_LIB=ON -DINSTALL_TO_MANGLED_PATHS=ON -DINSTALL_CREATE_DISTRIB=ON -DENABLE_FAST_MATH=ON -DWITH_IMAGEIO=ON -DWITH_CUBLAS=1 -DCUDA_FAST_MATH=1 -DWITH_GSTREAMER=ON -DCUDA_USE_STATIC_CUDA_RUNTIME=OFF ..

But it seems to result in a cuda related runtime error. Thanks.

andyli commented 7 years ago

I figured most things out, and created a dockerfile that will build VI-MEAN as an image: https://github.com/andyli/VI-MEAN/blob/docker/Dockerfile You may simply use docker or just reuse the RUN commands in a normal Ubuntu Trusty machine with CUDA sdk installed.

However, I don't see the reconstructed mesh in rviz when playing the sample.bag. I can see the ones in 2016-09-18-*.bag though.

jakeware commented 7 years ago

This worked for us. Thanks for your help.

Others should note that you have to update the gpu architecture by changing the 'CUDA_GENERATION' for the OpenCV build and the nvcc flags in stereo_mapper CMakeLists.txt.

maciejmatuszak commented 7 years ago

@jakeware did you build it with OpenCV 3.2.0 or 2.4. Did anyone build it under ros kinetic and OpenCV 3.2.0?

jakeware commented 7 years ago

@maciejmatuszak: We ran that docker build linked above with ros indigo and opencv 2.4.8.

David-Willo commented 7 years ago

@maciejmatuszak Have you solved the problem? I am now building it with OpenCV 3.2.0 and ROS Kinetic under Ubuntu 16.04 but got some error when running the ros node.The error message looks like this "OpenCV Error: Assertion failed (!fixedSize()) in release", there may be something wrong about the matrix.cpp of OpenCV3.2, but I can't figure out which line in the stereo_mapper source code lead to the error.

The only thing that I change is the stereobm part in the stereo_mapper_node.cpp, using bm->compute of OpenCV3 API instead of bm.operator() of OpenCV2 API. Some header files need to be change to migrate the code to OpenCV3. It can be complied successfully but the error at run time is a trouble.

Can someone give me some advice?


Edited on Oct 17 Recompile the project under Ubuntu14.04 with ROS Indigo and OpenCV2, everything works fine.

905805952 commented 6 years ago

@andyli Excuse me ,will see the reconstructed mesh in rviz when playing the sample.bag ?