ethz-asl / hand_eye_calibration

Python tools to perform time-synchronization and hand-eye calibration.
BSD 3-Clause "New" or "Revised" License
429 stars 115 forks source link

aslam_cv_common compilation fails. #97

Open eugval opened 3 years ago

eugval commented 3 years ago

Hello,

Thank you very much for that package, looks like a great way to do the calibration!

I am having some issues with compiling aslam_cv_common : Running catkin build hand_eye_calibration hand_eye_calibration_target_extractor hand_eye_calibration_batch_estimation

gives:


___________________________________________________________________________________________________________________________________________________________________________________________________________
Errors     << aslam_backend_expressions:make /home/Projects/extrinsics_calibration/logs/aslam_backend_expressions/build.make.001.log                                                                
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_solve'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_transpose'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_analyze'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_scale'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_start'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_free_dense'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_allocate_dense'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_free_dense'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_free_sparse'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_finish'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_start'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `int SuiteSparseQR_numeric<double>(double, cholmod_sparse_struct*, SuiteSparseQR_factorization<double>*, cholmod_common_struct*)'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_factorize'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `SuiteSparseQR_factorization<double>* SuiteSparseQR_symbolic<double>(int, int, cholmod_sparse_struct*, cholmod_common_struct*)'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_free_factor'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `int SuiteSparseQR_free<double>(SuiteSparseQR_factorization<double>**, cholmod_common_struct*)'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_l_finish'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_dense_struct* SuiteSparseQR_solve<double>(int, SuiteSparseQR_factorization<double>*, cholmod_dense_struct*, cholmod_common_struct*)'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_change_factor'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_amd'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_analyze_p'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `long SuiteSparseQR<double>(int, double, long, int, cholmod_sparse_struct*, cholmod_sparse_struct*, cholmod_dense_struct*, cholmod_sparse_struct**, cholmod_dense_struct**, cholmod_sparse_struct**, long**, cholmod_sparse_struct**, long**, cholmod_dense_struct**, cholmod_common_struct*)'
/home/Projects/extrinsics_calibration/devel/lib/libaslam_backend.so: undefined reference to `cholmod_dense_struct* SuiteSparseQR_qmult<double>(int, SuiteSparseQR_factorization<double>*, cholmod_dense_struct*, cholmod_common_struct*)'
collect2: error: ld returned 1 exit status
make[2]: *** [/home/Projects/extrinsics_calibration/devel/lib/aslam_backend_expressions/aslam_backend_expressions-profiling] Error 1
make[1]: *** [CMakeFiles/aslam_backend_expressions-profiling.dir/all] Error 2
make: *** [all] Error 2
cd /home/Projects/extrinsics_calibration/build/aslam_backend_expressions; catkin build --get-env aslam_backend_expressions | catkin env -si  /usr/bin/make --jobserver-fds=6,7 -j; cd -
...........................................................................................................................................................................................................
Failed     << aslam_backend_expressions:make                       [ Exited with code 2 ]                                                                                                                  
Failed    <<< aslam_backend_expressions                            [ 0.4 seconds ]                                                                                                                         
Abandoned <<< aslam_splines                                        [ Unrelated job failed ]                                                                                                                
Abandoned <<< oomact                                               [ Unrelated job failed ]                                                                                                                
Abandoned <<< hand_eye_calibration_batch_estimation                [ Unrelated job failed ]                                                                                                                
Abandoned <<< aslam_cv_cameras                                     [ Unrelated job failed ]                                                                                                                
Abandoned <<< aslam_cv_frames                                      [ Unrelated job failed ]                                                                                                                
Abandoned <<< aslam_cv_matcher                                     [ Unrelated job failed ]                                                                                                                
Abandoned <<< aslam_cv_geometric_vision                            [ Unrelated job failed ]                                                                                                                
Abandoned <<< aslam_cv_calibration                                 [ Unrelated job failed ]                                                                                                                
Abandoned <<< hand_eye_calibration_target_extractor                [ Unrelated job failed ]                                                                                                                
___________________________________________________________________________________________________________________________________________________________________________________________________________
Errors     << aslam_cv_common:cmake /home/Projects/extrinsics_calibration/logs/aslam_cv_common/build.cmake.014.log                                                                                  
CMake Error at /home/Projects/extrinsics_calibration/devel/share/catkin_simple/cmake/catkin_simple-extras.cmake:38 (find_package):
  By not providing "Findprotobuf_catkin.cmake" in CMAKE_MODULE_PATH this
  project has asked CMake to find a package configuration file provided by
  "protobuf_catkin", but CMake did not find one.

  Could not find a package configuration file provided by "protobuf_catkin"
  with any of the following names:

    protobuf_catkinConfig.cmake
    protobuf_catkin-config.cmake

  Add the installation prefix of "protobuf_catkin" to CMAKE_PREFIX_PATH or
  set "protobuf_catkin_DIR" to a directory containing one of the above files.
  If "protobuf_catkin" provides a separate development package or SDK, be
  sure it has been installed.
Call Stack (most recent call first):
  CMakeLists.txt:5 (catkin_simple)

cd /home/Projects/extrinsics_calibration/build/aslam_cv_common; catkin build --get-env aslam_cv_common | catkin env -si  /usr/bin/cmake /home/Projects/extrinsics_calibration/src/aslam_cv2/aslam_cv_common --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/Projects/extrinsics_calibration/devel -DCMAKE_INSTALL_PREFIX=/home/Projects/extrinsics_calibration/install -DCMAKE_BUILD_TYPE=Release; cd -
...........................................................................................................................................................................................................
Failed     << aslam_cv_common:cmake                                [ Exited with code 1 ]                                                                                                                  
Failed    <<< aslam_cv_common                                      [ 0.6 seconds ]                                                                                                                         
[build] Summary: 29 of 40 packages succeeded.                                                                                                                                                              
[build]   Ignored:   24 packages were skipped or are blacklisted.                                                                                                                                          
[build]   Warnings:  None.                                                                                                                                                                                 
[build]   Abandoned: 9 packages were abandoned.                                                                                                                                                            
[build]   Failed:    2 packages failed.                                                                                                                                                                    
[build] Runtime: 3.5 seconds total.        ```

Any Idea how to fix this or what could be causing this compilation error? 

Thanks!
eugval commented 3 years ago

Update:

After adding the following two lines : FIND_PACKAGE(SuiteSparse) include_directories(${SUITESPARSE_INCLUDE_DIRS})

To /src/suitesparse/system_suitesparse/CMakeLists.txt

The error is reduced to :


Starting  >>> oomact                                                                                                                                                                        
____________________________________________________________________________________________________________________________________________________________________________________________
Errors     << aslam_cv_common:cmake /home/eugene/Projects/extrinsics_calibration/logs/aslam_cv_common/build.cmake.016.log                                                                   
CMake Error at /home/eugene/Projects/extrinsics_calibration/devel/share/catkin_simple/cmake/catkin_simple-extras.cmake:38 (find_package):
  By not providing "Findprotobuf_catkin.cmake" in CMAKE_MODULE_PATH this
  project has asked CMake to find a package configuration file provided by
  "protobuf_catkin", but CMake did not find one.

  Could not find a package configuration file provided by "protobuf_catkin"
  with any of the following names:

    protobuf_catkinConfig.cmake
    protobuf_catkin-config.cmake

  Add the installation prefix of "protobuf_catkin" to CMAKE_PREFIX_PATH or
  set "protobuf_catkin_DIR" to a directory containing one of the above files.
  If "protobuf_catkin" provides a separate development package or SDK, be
  sure it has been installed.
Call Stack (most recent call first):
  CMakeLists.txt:5 (catkin_simple)

cd /home/eugene/Projects/extrinsics_calibration/build/aslam_cv_common; catkin build --get-env aslam_cv_common | catkin env -si  /usr/bin/cmake /home/eugene/Projects/extrinsics_calibration/src/aslam_cv2/aslam_cv_common --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/eugene/Projects/extrinsics_calibration/devel -DCMAKE_INSTALL_PREFIX=/home/eugene/Projects/extrinsics_calibration/install -DCMAKE_BUILD_TYPE=Release; cd -
............................................................................................................................................................................................
Failed     << aslam_cv_common:cmake                                [ Exited with code 1 ]                                                                                                   
Failed    <<< aslam_cv_common                                      [ 0.6 seconds ]                                                                                                          
Abandoned <<< hand_eye_calibration_batch_estimation                [ Unrelated job failed ]                                                                                                 
Abandoned <<< aslam_cv_cameras                                     [ Unrelated job failed ]                                                                                                 
Abandoned <<< aslam_cv_frames                                      [ Unrelated job failed ]                                                                                                 
Abandoned <<< aslam_cv_matcher                                     [ Unrelated job failed ]                                                                                                 
Abandoned <<< aslam_cv_geometric_vision                            [ Unrelated job failed ]                                                                                                 
Abandoned <<< aslam_cv_calibration                                 [ Unrelated job failed ]                                                                                                 
Abandoned <<< hand_eye_calibration_target_extractor                [ Unrelated job failed ]                                                                                                 
Finished  <<< oomact                                               [ 0.3 seconds ]                                                                                                          
[build] Summary: 32 of 40 packages succeeded.                                                                                                                                               
[build]   Ignored:   24 packages were skipped or are blacklisted.                                                                                                                           
[build]   Warnings:  None.                                                                                                                                                                  
[build]   Abandoned: 7 packages were abandoned.                                                                                                                                             
[build]   Failed:    1 packages failed.                                                                                                                                                     
[build] Runtime: 3.7 seconds total.       
OnyxBlack7 commented 3 years ago

I've met the same error. Have you solved it?

eugval commented 3 years ago

I haven't I'm afraid.

ardian-selmonaj commented 3 years ago

I had the same problem and solved it by cloning this package into src folder of catkin_ws. Then I first build this protobuf_catkin package and then extended the CMakeLists of aslam_cv_common with:

find_package(catkin_simple REQUIRED) find_package(protobuf_catkin REQUIRED) catkin_simple(ALL_DEPS_REQUIRED)

and then build the three hand-eye packages with catkin.

zhuxiaomengjj commented 3 years ago

I had the same problem and solved it by cloning this package into src folder of catkin_ws. Then I first build this protobuf_catkin package and then extended the CMakeLists of aslam_cv_common with:

find_package(catkin_simple REQUIRED) find_package(protobuf_catkin REQUIRED) catkin_simple(ALL_DEPS_REQUIRED)

and then build the three hand-eye packages with catkin.

Yes, it's helped, thanks

flyover-26 commented 2 years ago

I had the same problem and solved it by cloning this package into src folder of catkin_ws. Then I first build this protobuf_catkin package and then extended the CMakeLists of aslam_cv_common with:

find_package(catkin_simple REQUIRED) find_package(protobuf_catkin REQUIRED) catkin_simple(ALL_DEPS_REQUIRED)

and then build the three hand-eye packages with catkin.

hi!I got the same problem in project https://github.com/ethz-asl/mav_voxblox_planning#papers-and-references Could you tell me how to build the protobuf_catkin package? Thank you a lot!Looking forward to your reply! 屏幕截图 2021-11-10 19:18:29

flyover-26 commented 2 years ago

@ardian-selmonaj waiting for your help for problem above~

ardian-selmonaj commented 2 years ago

@flyover-26 as far as I remember, just the normal way: clone the protobuf_catkin package and run catkin build protobuf_catkin.

Hao-Starrr commented 1 year ago
cd ~/catkin_ws/src
git clone https://github.com/ethz-asl/protobuf_catkin.git
catkin build protobuf_catkin

Just clone and build. Then you can catkin_make again.