yanliang-wang / FAST_LIO_LC

The tight integration of FAST-LIO with Radius-Search-based loop closure module.
376 stars 76 forks source link

aloam_velodyne error #23

Closed GRF-Sunomikp31 closed 9 months ago

GRF-Sunomikp31 commented 1 year ago

Has anyone encountered the following problem?

[alaserPGO-1] process has died [pid 633386, exit code -11, cmd /home/doongli/catkin_ws_2/devel/lib/aloam_velodyne/alaserPGO /velodyne_points:=/velodyne_points /aft_mapped_to_init:=/Odometry /velodyne_cloud_registered_local:=/cloud_registered_body /cloud_for_scancontext:=/cloud_registered_lidar name:=alaserPGO log:=/home/doongli/.ros/log/b9fecd0e-4ad1-11ee-ba99-4f48c8864c97/alaserPGO-1.log]. log file: /home/doongli/.ros/log/b9fecd0e-4ad1-11ee-ba99-4f48c8864c97/alaserPGO-1*.log

GRF-Sunomikp31 commented 1 year ago

I used gtsam4.0.2

52SuyuZ commented 9 months ago

Have you solved this problem?

GRF-Sunomikp31 commented 9 months ago

Yep!but I forget how to solve it~

albertnew2012 commented 8 months ago

Hi @52SuyuZ I found the solution to solve this isse:

My original GTSAM is 4.0.3, which did not work. Then I found the following solution

wget -O ~/Downloads/gtsam.zip https://github.com/borglab/gtsam/archive/4.0.2.zip
cd ~/Downloads/ && unzip gtsam.zip -d ~/Downloads/
cd ~/Downloads/gtsam-4.0.2/
mkdir build && cd build
cmake -DGTSAM_BUILD_WITH_MARCH_NATIVE=OFF ..
sudo make install -j8

You may run into Cmake debug error mentioned here , please comment out the lines as below, as descibed in this post gtsam/wrap/CMakeLists.txt

set(WRAP_BOOST_LIBRARIES
  optimized
    ${Boost_FILESYSTEM_LIBRARY_RELEASE}
    ${Boost_SYSTEM_LIBRARY_RELEASE}
    ${Boost_THREAD_LIBRARY_RELEASE}
    #  debug
    #${Boost_FILESYSTEM_LIBRARY_DEBUG}
    #${Boost_SYSTEM_LIBRARY_DEBUG}
    #${Boost_THREAD_LIBRARY_DEBUG}
)

gtsam/CMakeLists.txt

if (GTSAM_DISABLE_NEW_TIMERS)
    message("WARNING:  GTSAM timing instrumentation manually disabled")
    list_append_cache(GTSAM_COMPILE_DEFINITIONS_PUBLIC DGTSAM_DISABLE_NEW_TIMERS)
else()
    if(Boost_TIMER_LIBRARY)
      list(APPEND GTSAM_BOOST_LIBRARIES
        optimized ${Boost_TIMER_LIBRARY_RELEASE}
        optimized ${Boost_CHRONO_LIBRARY_RELEASE}
        #debug ${Boost_TIMER_LIBRARY_DEBUG}
        #debug ${Boost_CHRONO_LIBRARY_DEBUG}
        )
    else()
      list(APPEND GTSAM_BOOST_LIBRARIES rt) # When using the header-only boost timer library, need -lrt
      message("WARNING:  GTSAM timing instrumentation will use the older, less accurate, Boost timer library because boost older than 1.48 was found.")
    endif()
endif()

Then it should work like a charm.

52SuyuZ commented 8 months ago

嗨,我找到了解决这个问题的解决方案:

我原来的GTSAM是4.0.3,它不起作用。然后我找到了以下解决方案

wget -O ~/Downloads/gtsam.zip https://github.com/borglab/gtsam/archive/4.0.2.zip
cd ~/Downloads/ && unzip gtsam.zip -d ~/Downloads/
cd ~/Downloads/gtsam-4.0.2/
mkdir build && cd build
cmake -DGTSAM_BUILD_WITH_MARCH_NATIVE=OFF ..
sudo make install -j8

您可能会遇到此处提到的Cmake调试错误,请注释掉以下行,如本文所述gtsam / wrap / CMakeLists.txt

set(WRAP_BOOST_LIBRARIES
  optimized
    ${Boost_FILESYSTEM_LIBRARY_RELEASE}
    ${Boost_SYSTEM_LIBRARY_RELEASE}
    ${Boost_THREAD_LIBRARY_RELEASE}
    #  debug
    #${Boost_FILESYSTEM_LIBRARY_DEBUG}
    #${Boost_SYSTEM_LIBRARY_DEBUG}
    #${Boost_THREAD_LIBRARY_DEBUG}
)

gtsam/CMakeLists.txt

if (GTSAM_DISABLE_NEW_TIMERS)
    message("WARNING:  GTSAM timing instrumentation manually disabled")
    list_append_cache(GTSAM_COMPILE_DEFINITIONS_PUBLIC DGTSAM_DISABLE_NEW_TIMERS)
else()
    if(Boost_TIMER_LIBRARY)
      list(APPEND GTSAM_BOOST_LIBRARIES
        optimized ${Boost_TIMER_LIBRARY_RELEASE}
        optimized ${Boost_CHRONO_LIBRARY_RELEASE}
        #debug ${Boost_TIMER_LIBRARY_DEBUG}
        #debug ${Boost_CHRONO_LIBRARY_DEBUG}
        )
    else()
      list(APPEND GTSAM_BOOST_LIBRARIES rt) # When using the header-only boost timer library, need -lrt
      message("WARNING:  GTSAM timing instrumentation will use the older, less accurate, Boost timer library because boost older than 1.48 was found.")
    endif()
endif()

然后它应该像魅力一样工作。

Thank you very much for your answer, it is very useful for me!