Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build openMVG on ubuntu #1455

Closed
godblezzme29 opened this issue Dec 24, 2018 · 8 comments
Closed

Build openMVG on ubuntu #1455

godblezzme29 opened this issue Dec 24, 2018 · 8 comments

Comments

@godblezzme29
Copy link

Hello, I tried to build openMVG based on the instructions
but it has error when build openMVG_sample_multiview_robustEssential_spherical, is there anyone have this problem and able to solve it?? Thank you

This is the following error from the terminal
[ 71%] Linking CXX executable ../../Linux-x86_64-RELEASE/openMVG_sample_multiview_robustEssential_spherical
/usr/local/lib/libceres.a(reorder_program.cc.o): In function ceres::internal::MaybeReorderSchurComplementColumnsUsingSuiteSparse(ceres::OrderedGroups<double*> const&, ceres::internal::Program*)': reorder_program.cc:(.text+0x1ba): undefined reference to cholmod_free_sparse'
/usr/local/lib/libceres.a(reorder_program.cc.o): In function ceres::internal::(anonymous namespace)::OrderingForSparseNormalCholeskyUsingSuiteSparse(ceres::internal::TripletSparseMatrix const&, std::vector<ceres::internal::ParameterBlock*, std::allocator<ceres::internal::ParameterBlock*> > const&, ceres::OrderedGroups<double*> const&, int*) [clone .constprop.182]': reorder_program.cc:(.text+0x4c6): undefined reference to cholmod_free_sparse'
/usr/local/lib/libceres.a(schur_complement_solver.cc.o): In function ceres::internal::SparseSchurComplementSolver::~SparseSchurComplementSolver()': schur_complement_solver.cc:(.text+0x2029): undefined reference to cholmod_free_factor'
/usr/local/lib/libceres.a(schur_complement_solver.cc.o): In function ceres::internal::SparseSchurComplementSolver::SolveReducedLinearSystemUsingSuiteSparse(ceres::internal::LinearSolver::PerSolveOptions const&, double*)': schur_complement_solver.cc:(.text+0x3330): undefined reference to cholmod_free_sparse'
schur_complement_solver.cc:(.text+0x337d): undefined reference to cholmod_free_dense' schur_complement_solver.cc:(.text+0x33c3): undefined reference to cholmod_free_dense'
schur_complement_solver.cc:(.text+0x3458): undefined reference to cholmod_free_sparse' /usr/local/lib/libceres.a(sparse_normal_cholesky_solver.cc.o): In function ceres::internal::SparseNormalCholeskySolver::FreeFactorization()':
sparse_normal_cholesky_solver.cc:(.text+0x33): undefined reference to cholmod_free_factor' /usr/local/lib/libceres.a(sparse_normal_cholesky_solver.cc.o): In function ceres::internal::SparseNormalCholeskySolver::SolveImplUsingSuiteSparse(ceres::internal::CompressedRowSparseMatrix*, ceres::internal::LinearSolver::PerSolveOptions const&, double*)':
sparse_normal_cholesky_solver.cc:(.text+0x4ce): undefined reference to cholmod_free_dense' sparse_normal_cholesky_solver.cc:(.text+0x500): undefined reference to cholmod_free_dense'
sparse_normal_cholesky_solver.cc:(.text+0x5ca): undefined reference to cholmod_free_factor' /usr/local/lib/libceres.a(sparse_normal_cholesky_solver.cc.o): In function ceres::internal::SparseNormalCholeskySolver::~SparseNormalCholeskySolver()':
sparse_normal_cholesky_solver.cc:(.text+0xed9): undefined reference to cholmod_free_factor' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::CreateSparseMatrix(ceres::internal::TripletSparseMatrix*)':
suitesparse.cc:(.text+0xd1): undefined reference to cholmod_triplet_to_sparse' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::CreateSparseMatrixTranspose(ceres::internal::TripletSparseMatrix*)':
suitesparse.cc:(.text+0x1f1): undefined reference to cholmod_triplet_to_sparse' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::AnalyzeCholesky(cholmod_sparse_struct*, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
suitesparse.cc:(.text+0x3c0): undefined reference to cholmod_analyze' suitesparse.cc:(.text+0x3e8): undefined reference to cholmod_print_common'
/usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::AnalyzeCholeskyWithNaturalOrdering(cholmod_sparse_struct*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*)': suitesparse.cc:(.text+0x583): undefined reference to cholmod_analyze'
suitesparse.cc:(.text+0x5ab): undefined reference to cholmod_print_common' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::BlockAMDOrdering(cholmod_sparse_struct const
, std::vector<int, std::allocator > const&, std::vector<int, std::allocator > const&, std::vector<int, std::allocator >)':
suitesparse.cc:(.text+0x896): undefined reference to cholmod_amd' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::Cholesky(cholmod_sparse_struct
, cholmod_factor_struct*, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
suitesparse.cc:(.text+0x9c5): undefined reference to cholmod_factorize' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::ApproximateMinimumDegreeOrdering(cholmod_sparse_struct
, int*)':
suitesparse.cc:(.text+0xcc2): undefined reference to cholmod_amd' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::ConstrainedApproximateMinimumDegreeOrdering(cholmod_sparse_struct*, int*, int*)':
suitesparse.cc:(.text+0xce5): undefined reference to cholmod_camd' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::CreateDenseVector(double const*, int, int)':
suitesparse.cc:(.text+0xd3d): undefined reference to cholmod_zeros' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::AnalyzeCholeskyWithUserOrdering(cholmod_sparse_struct*, std::vector<int, std::allocator > const&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
suitesparse.cc:(.text+0xe5c): undefined reference to cholmod_analyze_p' suitesparse.cc:(.text+0xe84): undefined reference to cholmod_print_common'
/usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::BlockAnalyzeCholesky(cholmod_sparse_struct*, std::vector<int, std::allocator<int> > const&, std::vector<int, std::allocator<int> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*)': suitesparse.cc:(.text+0x10db): undefined reference to cholmod_analyze_p'
suitesparse.cc:(.text+0x1103): undefined reference to cholmod_print_common' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::SuiteSparse()':
suitesparse.cc:(.text+0x1): undefined reference to cholmod_start' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::~SuiteSparse()':
suitesparse.cc:(.text+0x11): undefined reference to cholmod_finish' /usr/local/lib/libceres.a(suitesparse.cc.o): In function ceres::internal::SuiteSparse::Solve(cholmod_factor_struct
, cholmod_dense_struct*, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
suitesparse.cc:(.text+0xc80): undefined reference to cholmod_solve' /usr/local/lib/libceres.a(visibility_based_preconditioner.cc.o): In function ceres::internal::VisibilityBasedPreconditioner::RightMultiply(double const
, double*) const':
visibility_based_preconditioner.cc:(.text+0x14f): undefined reference to cholmod_free_dense' /usr/local/lib/libceres.a(visibility_based_preconditioner.cc.o): In function ceres::internal::VisibilityBasedPreconditioner::Factorize()':
visibility_based_preconditioner.cc:(.text+0xbb6): undefined reference to cholmod_free_sparse' /usr/local/lib/libceres.a(visibility_based_preconditioner.cc.o): In function ceres::internal::VisibilityBasedPreconditioner::~VisibilityBasedPreconditioner()':
visibility_based_preconditioner.cc:(.text+0x128e): undefined reference to cholmod_free_factor' visibility_based_preconditioner.cc:(.text+0x12b7): undefined reference to cholmod_free_dense'
collect2: error: ld returned 1 exit status
openMVG_Samples/multiview_robust_essential_spherical/CMakeFiles/openMVG_sample_multiview_robustEssential_spherical.dir/build.make:127: recipe for target 'Linux-x86_64-RELEASE/openMVG_sample_multiview_robustEssential_spherical' failed
make[2]: *** [Linux-x86_64-RELEASE/openMVG_sample_multiview_robustEssential_spherical] Error 1
CMakeFiles/Makefile2:2793: recipe for target 'openMVG_Samples/multiview_robust_essential_spherical/CMakeFiles/openMVG_sample_multiview_robustEssential_spherical.dir/all' failed
make[1]: *** [openMVG_Samples/multiview_robust_essential_spherical/CMakeFiles/openMVG_sample_multiview_robustEssential_spherical.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

@pmoulon
Copy link
Member

pmoulon commented Dec 28, 2018

Seems like you are using an external Ceres configured with SuiteSparse and cholmod.
Can you tell me which version?

It seems that on your machine the ceres import does not bring ceres dependency transitively (cholmod).

@godblezzme29
Copy link
Author

Seems like you are using an external Ceres configured with SuiteSparse and cholmod.
Can you tell me which version?

It seems that on your machine the ceres import does not bring ceres dependency transitively (cholmod).

Hello sorry for late reply
Currently I use ceres 1.14.0 version
I installed the ceres-solver based on the ceres-solver website's http://ceres-solver.org/installation.html
I still failed to install openMVG
Btw thanks for the reply

@joshuajano
Copy link

Hello, i triend to install openMVG on Ubuntu 16.04 and follow the instruction in this https://github.com/openMVG/openMVG. But, i found an error
-- Lemon 1.3 found (include: /home/joshuajano/openMVG/src/third_party/lemon/lemon)
-- Could NOT find COIN (missing: COIN_INCLUDE_DIR COIN_CBC_LIBRARY COIN_CBC_SOLVER_LIBRARY COIN_CGL_LIBRARY COIN_CLP_LIBRARY COIN_COIN_UTILS_LIBRARY COIN_OSI_LIBRARY COIN_OSI_CBC_LIBRARY COIN_OSI_CLP_LIBRARY)
can anyone solve this?

@pmoulon
Copy link
Member

pmoulon commented Jul 11, 2019

@joshuajano Can you try the develop branch?

@joshuajano
Copy link

Dear Mr. Pierre, thank you so much for your respond, i will try it

@pmoulon
Copy link
Member

pmoulon commented Jul 11, 2019

OpenMVG should compile without issues on Ubuntu, see the docker on develop branch:
https://github.com/openMVG/openMVG/blob/develop/Dockerfile

@joshuajano
Copy link

Thank you so much for your help, after i ran this command "ctest --output-on-failure -j".
I got this output:
Start 1: openMVG_test_Camera_Pinhole
1/80 Test #1: openMVG_test_Camera_Pinhole .............................. Passed 0.19 sec
Start 2: openMVG_test_Camera_Pinhole_Radial
2/80 Test #2: openMVG_test_Camera_Pinhole_Radial ....................... Passed 1.41 sec
Start 3: openMVG_test_Camera_Pinhole_Brown
3/80 Test #3: openMVG_test_Camera_Pinhole_Brown ........................ Passed 0.43 sec
Start 4: openMVG_test_Camera_Pinhole_Fisheye
4/80 Test #4: openMVG_test_Camera_Pinhole_Fisheye ...................... Passed 0.58 sec
Start 5: openMVG_test_Camera_Spherical
5/80 Test #5: openMVG_test_Camera_Spherical ............................ Passed 0.47 sec
Start 6: openMVG_test_Camera_Subset_Parametrization
6/80 Test #6: openMVG_test_Camera_Subset_Parametrization ............... Passed 0.00 sec
Start 7: openMVG_test_Camera_IO
7/80 Test #7: openMVG_test_Camera_IO ................................... Passed 0.07 sec
Start 8: openMVG_test_exif_IO
8/80 Test #8: openMVG_test_exif_IO ..................................... Passed 0.07 sec
Start 9: openMVG_test_ParseDatabase
9/80 Test #9: openMVG_test_ParseDatabase ............................... Passed 0.08 sec
Start 10: openMVG_test_features
10/80 Test #10: openMVG_test_features .................................... Passed 0.00 sec
Start 11: openMVG_test_image_describer
11/80 Test #11: openMVG_test_image_describer ............................. Passed 0.05 sec
Start 12: openMVG_test_akaze
12/80 Test #12: openMVG_test_akaze ....................................... Passed 2.08 sec
Start 13: openMVG_test_mser
13/80 Test #13: openMVG_test_mser ........................................ Passed 0.19 sec
Start 14: openMVG_test_sift
14/80 Test #14: openMVG_test_sift ........................................ Passed 0.30 sec
Start 15: openMVG_test_tbmr
15/80 Test #15: openMVG_test_tbmr ........................................ Passed 0.07 sec
Start 16: openMVG_graph_test_connectedComponent
16/80 Test #16: openMVG_graph_test_connectedComponent .................... Passed 0.00 sec
Start 17: openMVG_graph_test_triplet_finder
17/80 Test #17: openMVG_graph_test_triplet_finder ........................ Passed 0.03 sec
Start 18: openMVG_test_image
18/80 Test #18: openMVG_test_image ....................................... Passed 0.01 sec
Start 19: openMVG_test_image_drawing
19/80 Test #19: openMVG_test_image_drawing ............................... Passed 0.01 sec
Start 20: openMVG_test_image_integral
20/80 Test #20: openMVG_test_image_integral .............................. Passed 0.00 sec
Start 21: openMVG_test_image_io
21/80 Test #21: openMVG_test_image_io .................................... Passed 0.05 sec
Start 22: openMVG_test_image_filtering
22/80 Test #22: openMVG_test_image_filtering ............................. Passed 0.03 sec
Start 23: openMVG_test_image_resampling
23/80 Test #23: openMVG_test_image_resampling ............................ Passed 4.16 sec
Start 24: openMVG_test_linearProgramming
24/80 Test #24: openMVG_test_linearProgramming ........................... Passed 0.16 sec
Start 25: openMVG_lInftyCV_test_triangulation
25/80 Test #25: openMVG_lInftyCV_test_triangulation ...................... Passed 0.17 sec
Start 26: openMVG_lInftyCV_test_resection
26/80 Test #26: openMVG_lInftyCV_test_resection .......................... Passed 0.27 sec
Start 27: openMVG_lInftyCV_test_resection_robust
27/80 Test #27: openMVG_lInftyCV_test_resection_robust ................... Passed 2.00 sec
Start 28: openMVG_lInftyCV_test_global_translations_fromTriplets
28/80 Test #28: openMVG_lInftyCV_test_global_translations_fromTriplets ... Passed 0.11 sec
Start 29: openMVG_lInftyCV_test_global_translations_fromTij
29/80 Test #29: openMVG_lInftyCV_test_global_translations_fromTij ........ Passed 0.17 sec
Start 30: openMVG_lInftyCV_test_tijsAndXis
30/80 Test #30: openMVG_lInftyCV_test_tijsAndXis ......................... Passed 0.18 sec
Start 31: openMVG_lInftyCV_test_tijsAndXis_outlier
31/80 Test #31: openMVG_lInftyCV_test_tijsAndXis_outlier ................. Passed 0.21 sec
Start 32: openMVG_geodesy_test_geodesy
32/80 Test #32: openMVG_geodesy_test_geodesy ............................. Passed 0.01 sec
Start 33: openMVG_test_convex_hull
33/80 Test #33: openMVG_test_convex_hull ................................. Passed 0.02 sec
Start 34: openMVG_test_rigid_transformation3D_srt
34/80 Test #34: openMVG_test_rigid_transformation3D_srt .................. Passed 0.01 sec
Start 35: openMVG_test_plane_estimation_kernel
35/80 Test #35: openMVG_test_plane_estimation_kernel ..................... Passed 0.04 sec
Start 36: openMVG_test_half_space_intersection
36/80 Test #36: openMVG_test_half_space_intersection ..................... Passed 0.33 sec
Start 37: openMVG_test_frustum_intersection
37/80 Test #37: openMVG_test_frustum_intersection ........................ Passed 0.38 sec
Start 38: openMVG_test_frustum_box_intersection
38/80 Test #38: openMVG_test_frustum_box_intersection .................... Passed 0.26 sec
Start 39: openMVG_test_matching
39/80 Test #39: openMVG_test_matching .................................... Passed 0.06 sec
Start 40: openMVG_test_matching_filters
40/80 Test #40: openMVG_test_matching_filters ............................ Passed 0.02 sec
Start 41: openMVG_test_indMatch
41/80 Test #41: openMVG_test_indMatch .................................... Passed 0.04 sec
Start 42: openMVG_test_metric
42/80 Test #42: openMVG_test_metric ...................................... Passed 0.02 sec
Start 43: openMVG_test_Pair_Builder
43/80 Test #43: openMVG_test_Pair_Builder ................................ Passed 0.01 sec
Start 44: openMVG_test_triangulation
44/80 Test #44: openMVG_test_triangulation ............................... Passed 0.01 sec
Start 45: openMVG_test_triangulation_nview
45/80 Test #45: openMVG_test_triangulation_nview ......................... Passed 0.06 sec
Start 46: openMVG_test_solver_affine
46/80 Test #46: openMVG_test_solver_affine ............................... Passed 0.05 sec
Start 47: openMVG_test_solver_essential_eight_point
47/80 Test #47: openMVG_test_solver_essential_eight_point ................ Passed 0.01 sec
Start 48: openMVG_test_solver_essential_five_point
48/80 Test #48: openMVG_test_solver_essential_five_point ................. Passed 0.09 sec
Start 49: openMVG_test_solver_essential_three_point
49/80 Test #49: openMVG_test_solver_essential_three_point ................ Passed 0.03 sec
Start 50: openMVG_test_solver_fundamental_kernel
50/80 Test #50: openMVG_test_solver_fundamental_kernel ................... Passed 0.02 sec
Start 51: openMVG_test_solver_homography_kernel
51/80 Test #51: openMVG_test_solver_homography_kernel .................... Passed 0.06 sec
Start 52: openMVG_test_solver_resection_kernel
52/80 Test #52: openMVG_test_solver_resection_kernel ..................... Passed 0.05 sec
Start 53: openMVG_test_solver_translation_knownRotation_kernel
53/80 Test #53: openMVG_test_solver_translation_knownRotation_kernel ..... Passed 0.05 sec
Start 54: openMVG_test_rotation_averaging
54/80 Test #54: openMVG_test_rotation_averaging .......................... Passed 0.72 sec
Start 55: openMVG_test_translation_averaging
55/80 Test #55: openMVG_test_translation_averaging ....................... Passed 0.24 sec
Start 56: openMVG_test_extract_columns
56/80 Test #56: openMVG_test_extract_columns ............................. Passed 0.04 sec
Start 57: openMVG_test_numeric
57/80 Test #57: openMVG_test_numeric ..................................... Passed 0.01 sec
Start 58: openMVG_test_poly
58/80 Test #58: openMVG_test_poly ........................................ Passed 0.01 sec
Start 59: openMVG_test_lm
59/80 Test #59: openMVG_test_lm .......................................... Passed 0.01 sec
Start 60: openMVG_test_l1_solver
60/80 Test #60: openMVG_test_l1_solver ................................... Passed 0.21 sec
Start 61: openMVG_test_rand_sampling
61/80 Test #61: openMVG_test_rand_sampling ............................... Passed 0.03 sec
Start 62: openMVG_test_robust_estimator_lineKernel
62/80 Test #62: openMVG_test_robust_estimator_lineKernel ................. Passed 0.02 sec
Start 63: openMVG_test_robust_estimator_MaxConsensus
63/80 Test #63: openMVG_test_robust_estimator_MaxConsensus ............... Passed 0.01 sec
Start 64: openMVG_test_robust_estimator_Ransac
64/80 Test #64: openMVG_test_robust_estimator_Ransac ..................... Passed 0.02 sec
Start 65: openMVG_test_robust_estimator_ACRansac
65/80 Test #65: openMVG_test_robust_estimator_ACRansac ................... Passed 0.05 sec
Start 66: openMVG_test_gms_filter
66/80 Test #66: openMVG_test_gms_filter .................................. Passed 0.02 sec
Start 67: openMVG_test_tracks
67/80 Test #67: openMVG_test_tracks ...................................... Passed 0.01 sec
Start 68: openMVG_test_global_quantile_gain_offset_alignment
68/80 Test #68: openMVG_test_global_quantile_gain_offset_alignment ....... Passed 0.11 sec
Start 69: openMVG_test_progress
69/80 Test #69: openMVG_test_progress .................................... Passed 0.04 sec
Start 70: openMVG_test_sfm_data_io
70/80 Test #70: openMVG_test_sfm_data_io ................................. Passed 0.07 sec
Start 71: openMVG_test_sfm_data_BA
71/80 Test #71: openMVG_test_sfm_data_BA ................................. Passed 0.16 sec
Start 72: openMVG_test_sfm_data_utils
72/80 Test #72: openMVG_test_sfm_data_utils .............................. Passed 0.02 sec
Start 73: openMVG_test_sfm_data_filters
73/80 Test #73: openMVG_test_sfm_data_filters ............................ Passed 0.01 sec
Start 74: openMVG_test_sfm_data_graph_utils
74/80 Test #74: openMVG_test_sfm_data_graph_utils ........................ Passed 0.01 sec
Start 75: openMVG_test_global_SfM
75/80 Test #75: openMVG_test_global_SfM .................................. Passed 2.52 sec
Start 76: openMVG_test_sequential_SfM
76/80 Test #76: openMVG_test_sequential_SfM .............................. Passed 0.45 sec
Start 77: openMVG_test_sequential_SfM2
77/80 Test #77: openMVG_test_sequential_SfM2 ............................. Passed 0.33 sec
Start 78: openMVG_test_stellar_SfM
78/80 Test #78: openMVG_test_stellar_SfM ................................. Passed 0.31 sec
Start 79: openMVG_test_split
79/80 Test #79: openMVG_test_split ....................................... Passed 0.04 sec
Start 80: openMVG_test_dynamic_bitset
80/80 Test #80: openMVG_test_dynamic_bitset .............................. Passed 0.02 sec

100% tests passed, 0 tests failed out of 80

Total Test time (real) = 21.18 sec

@pmoulon
Copy link
Member

pmoulon commented Jul 12, 2019

Great you are ready to go! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants