Git Product home page Git Product logo

Comments (16)

Camilochiang avatar Camilochiang commented on June 8, 2024 1

So it look that you have a mess.

  1. First starting by removing all your custom installations (you may need to install purge)
    sudo apt-get purge '*opencv*'
    now check the version of opencv
    pkg-config --modversion opencv
    This should give you the default version in your machine before all your installations or none, not sure.
  2. Re instally opencv
sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
# I download the 3.4.16 version and decompress on /home/ubuntu
cd /home/ubuntu/opencv-3.4.16
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local ..
sudo make install
pkg-config --modversion opencv

ps: dont change anything of r3live dude. your problem is on opencv, not r3live

from r3live.

Camilochiang avatar Camilochiang commented on June 8, 2024 1

If you install opencv 3.4.16 and install from source cv-bridge, then you should be fine...
https://github.com/ros-perception/vision_opencv

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

The console gives this kind of error:
/ws_livox/src/r3live/r3live/src/loam/IMU_Processing.cpp, 132, check_state fail !!!! 0.793862 3.76128 -10.1187
here is my pc software version:
2022-01-05 12-03-26屏幕截图

from r3live.

ziv-lin avatar ziv-lin commented on June 8, 2024

With referring to issue #11
I suggest you check if the OpenCV you use for compiling the codes matches exactly the openCV in your runtime environment. That is, the OpenCV version oriented by R3LIVE should as the same as the version info printed in your terminal after types:

pkg-config --modversion opencv

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

@ziv-lin Hi, I have tried several time to uninstall OpenCV whitch I build from source code. And I check OpenCV version:
2022-01-06 00-13-10屏幕截图
But after delete OpenCV, I compile r3live. It success with cv 3.3.1 whitch is installed by Ros-Kinetic-visionCV :
2022-01-06 00-12-47屏幕截图
Then I replay rosbag, i get error:
2022-01-06 00-20-44屏幕截图

It Seems that IMU-Processing works in the wrong way. Should I remove kinetic-ros opencv, and then try to build cv from source code?

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

I also try build cv 3.3.1 from source code. and then pkg-config --modversion opencvcheck OpenCV version with 3.3.1.
Run and get IMU_Processing errors. The result is that Lidar moving Path and Color Point Cloud not mapping as expected.

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

I change set(OpenCV_DIR "/home/cmown/opencv-3.4.16/build") in the r3live CMakeLists.txt . And console outputs like this:
2022-01-06 16-39-16屏幕截图
But when it success compiling, run and get opencv3.3.1:
2022-01-06 16-42-35屏幕截图
type pkg-config --modversion opencv, I got opencv3.4.16. So I really don't know how to set opencv right version

from r3live.

ziv-lin avatar ziv-lin commented on June 8, 2024

Make sure that the LIBRARY you build and run with the same is very very important to achieve the correct result you expected. If you have some troubles in modifying your current software environment, I suggest your try R3LIVE in a new clean machine to see if it work.

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

Make sure that the LIBRARY you build and run with the same is very very important to achieve the correct result you expected. If you have some troubles in modifying your current software environment, I suggest your try R3LIVE in a new clean machine to see if it work.

So it look that you have a mess.

1. First starting by removing all your custom installations (you may need to install purge)
   `sudo apt-get purge '*opencv*' `
   now check the version of opencv
   `pkg-config --modversion opencv`
   This should give you the default version in your machine before all your installations or none, not sure.

2. Re instally opencv
sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
# I download the 3.4.16 version and decompress on /home/ubuntu
cd /home/ubuntu/opencv-3.4.16
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local ..
sudo make install
pkg-config --modversion opencv

ps: dont change anything of r3live dude. your problem is on opencv, not r3live

Hi C.
thanks to giving these steps. After doing this and catkin build r3live, it cause cmake error: Missing cv-brige . So I have to apt-get install this ros-xxx-cv-bridge. But this apt instruction lead to install ROS-Opencv with 3.3.1 in the path "/opt/ros/kinetic/include/opencv-3.3.1-dev". Finally r3live compliled with 3.3.1 not 3.4.16
My confuseing is why cv3.3.1 works in a wired way in my first post image. I notice that I installed Sophus lib with fuzzy CV version, does this cause some trouble?

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

Make sure that the LIBRARY you build and run with the same is very very important to achieve the correct result you expected. If you have some troubles in modifying your current software environment, I suggest your try R3LIVE in a new clean machine to see if it work.

Sure that is final way. Thanks to your nice work Lin! Cheer For U!
ps:any new i will post here :d

from r3live.

Camilochiang avatar Camilochiang commented on June 8, 2024

What do you get now from pkg-config --modversion opencv ?

from r3live.

Camilochiang avatar Camilochiang commented on June 8, 2024

Maybe repeat the process installing cv-bridge before..

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

What do you get now from pkg-config --modversion opencv ?

after purge and install 3.4.16. pkg-config is 3.4.16. but compile r3live is 3.3.1

if i purge opencv*, then i got 3.4.16(because i build it myself and make install. and i make uninstall, then i got nothing. it say missing opencv.

from r3live.

Marshall-Hu avatar Marshall-Hu commented on June 8, 2024

If you install opencv 3.4.16 and install from source cv-bridge, then you should be fine... https://github.com/ros-perception/vision_opencv

Yeah, I finally get the right answer.
And through my trip, Eigen version and opencv version should be kind of couple:
cv3.4.16 seems not working with Eigen.version > 3.3.7 while compile r3live. so here is my:
2022-01-07 00-59-44屏幕截图

Thx again C.

from r3live.

mameesie avatar mameesie commented on June 8, 2024

@ziv-lin Hi, I have tried several time to uninstall OpenCV whitch I build from source code. And I check OpenCV version: 2022-01-06 00-13-10屏幕截图 But after delete OpenCV, I compile r3live. It success with cv 3.3.1 whitch is installed by Ros-Kinetic-visionCV : 2022-01-06 00-12-47屏幕截图 Then I replay rosbag, i get error: 2022-01-06 00-20-44屏幕截图

It Seems that IMU-Processing works in the wrong way. Should I remove kinetic-ros opencv, and then try to build cv from source code?

Hi, I still have this "check_state fail" error when running my own setup. Even after building and running with same openCV. The error occurs when I capture objects at < 2.5 meters. when capturing objects at long range it will work perfectly. Is this normal behaviour?

image

from r3live.

cywm39 avatar cywm39 commented on June 8, 2024

@mameesie I have the same problem. Have you solved it?

from r3live.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.