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

Compiling error: ‘Model::points_’ is not a variable in clause ‘shared’ #1

Open
hhhhhli opened this issue Jul 9, 2020 · 3 comments

Comments

@hhhhhli
Copy link

hhhhhli commented Jul 9, 2020

Hi,
Thanks for sharing your inspiring and useful project.
I got an error when compling it (executing make Display), and the error message is shown below.

/home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘double Model::Score()’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::tangs_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::tang_scores_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::hope_dist_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::views_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:103:140: error: ‘Model::spanning_tree_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘void Model::DeleteOutliers()’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:384:92: error: ‘Model::n_points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:384:92: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘double Model::UpdatePointsSplitAndSolve(bool, Graph*, Graph*)’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1151:130: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1151:130: error: ‘Model::tangs_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1151:130: error: ‘Model::tang_scores_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1151:130: error: ‘Model::hope_dist_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1151:130: error: ‘Model::views_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1168:100: error: ‘Model::n_points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1168:100: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1168:100: error: ‘Model::points_feasible_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘void Model::Update3DRadius(double)’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1756:130: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1756:130: error: ‘Model::tangs_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1756:130: error: ‘Model::tang_scores_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1756:130: error: ‘Model::hope_dist_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:1756:130: error: ‘Model::views_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘void Model::UpdateViews()’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2057:72: error: ‘Model::views_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp: In member function ‘void Model::RecoverUncertainRadius(Graph*)’: /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2753:130: error: ‘Model::points_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2753:130: error: ‘Model::tangs_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2753:130: error: ‘Model::tang_scores_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2753:130: error: ‘Model::hope_dist_’ is not a variable in clause ‘shared’ /home/hl/3D_reconstruction/Vid2Curve/src/Core/Model.cpp:2753:130: error: ‘Model::views_’ is not a variable in clause ‘shared’ CMakeFiles/Display.dir/build.make:231: recipe for target 'CMakeFiles/Display.dir/src/Core/Model.cpp.o' failed make[3]: *** [CMakeFiles/Display.dir/src/Core/Model.cpp.o] Error 1 CMakeFiles/Makefile2:75: recipe for target 'CMakeFiles/Display.dir/all' failed make[2]: *** [CMakeFiles/Display.dir/all] Error 2 CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/Display.dir/rule' failed make[1]: *** [CMakeFiles/Display.dir/rule] Error 2 Makefile:118: recipe for target 'Display' failed make: *** [Display] Error 2

Have you ever encountered this error? If yes, could you please tell me how to fix it?
Thank you very much :)

@lyp0413
Copy link

lyp0413 commented Aug 18, 2020

@hhhhhli
Hi,I met the same error as you.
If you have solved this problem,please share me the way.
Thank U!

@Totoro97
Copy link
Owner

Totoro97 commented Aug 19, 2020

Hi @lyp0413
I guess it is due to that your OpenMP version or GCC version is too old. Could you update your OpenMP and GCC and try it again?

Thank you!

@zengchao23
Copy link

Hi, Thanks for sharing your inspiring and useful project.
I have a big problem. when I run this command - ./Display , this error occur --chao@chao:~/Vid2Curve/build$ ./Display

0% 10 20 30 40 50 60 70 80 90 100%
|----|----|----|----|----|----|----|----|----|----|
***段错误。
I also changed many, many datasets,It's useless, it's all this error!Only by switching to that dataset named star will it work successfully.Except for this, everyone else has this error. cmake and make have no errors,
My terminal is Ubuntu 18.04
Below is my entire process code:
chao@chao:~/Vid2Curve/build$ cmake .. -DUSE_GUI=1
-- The CXX compiler identification is GNU 7.5.0
-- The C compiler identification is GNU 7.5.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Found installed version of Eigen: /usr/local/share/eigen3/cmake
-- Found required Ceres dependency: Eigen version 3.3.7 in /usr/local/include/eigen3
-- Found installed version of glog: /usr/local/lib/cmake/glog
-- Detected glog version: 0.7.0
-- Found required Ceres dependency: glog
-- Found installed version of gflags: /usr/lib/x86_64-linux-gnu/cmake/gflags
-- Detected gflags version: 2.2.1
-- Found required Ceres dependency: gflags
-- Found Ceres version: 1.14.0 installed in: /usr/local with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, SchurSpecializations, OpenMP, Multithreading]
-- Found OpenCV: /home/chao/opencv-4.3.0/build (found version "4.3.0")
-- Found OpenMP_C: -fopenmp (found version "4.5")
-- Found OpenMP_CXX: -fopenmp (found version "4.5")
-- Found OpenMP: TRUE (found version "4.5")
-- OpenMP flags = -fopenmp
-- Found Boost: /home/chao/boost_1_72_0 (found version "1.72.0") found components: filesystem system
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:

USE_GUI

-- Build files have been written to: /home/chao/Vid2Curve/build
chao@chao:/Vid2Curve/build$ make Display
Scanning dependencies of target Display
[ 2%] Building CXX object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/OFDIS.cpp.o
[ 5%] Building C object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/image.c.o
[ 8%] Building CXX object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/oflow.cpp.o
[ 11%] Building C object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/opticalflow_aux.c.o
[ 14%] Building CXX object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/patch.cpp.o
[ 17%] Building CXX object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/patchgrid.cpp.o
[ 20%] Building CXX object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/refine_variational.cpp.o
[ 22%] Building C object CMakeFiles/Display.dir/src/Utils/FastOpticalFlow/solver.c.o
[ 25%] Building CXX object CMakeFiles/Display.dir/src/Utils/LSQR/lsqrBase.cpp.o
[ 28%] Building CXX object CMakeFiles/Display.dir/src/Utils/LSQR/lsqrSparse.cpp.o
[ 31%] Building CXX object CMakeFiles/Display.dir/src/Core/CurveExtractor.cpp.o
[ 34%] Building CXX object CMakeFiles/Display.dir/src/Core/CurveMatcher.cpp.o
[ 37%] Building CXX object CMakeFiles/Display.dir/src/Core/Initializer.cpp.o
[ 40%] Building CXX object CMakeFiles/Display.dir/src/Core/Model.cpp.o
[ 42%] Building CXX object CMakeFiles/Display.dir/src/Core/View.cpp.o
[ 45%] Building CXX object CMakeFiles/Display.dir/src/Utils/BezierCurve.cpp.o
[ 48%] Building CXX object CMakeFiles/Display.dir/src/Utils/Camera.cpp.o
[ 51%] Building CXX object CMakeFiles/Display.dir/src/Utils/CubeSet.cpp.o
[ 54%] Building CXX object CMakeFiles/Display.dir/src/Utils/GlobalDataPool.cpp.o
[ 57%] Building CXX object CMakeFiles/Display.dir/src/Utils/Graph.cpp.o
[ 60%] Building CXX object CMakeFiles/Display.dir/src/Utils/ICP.cpp.o
[ 62%] Building CXX object CMakeFiles/Display.dir/src/Utils/KMeansClustering.cpp.o
[ 65%] Building CXX object CMakeFiles/Display.dir/src/Utils/Loader.cpp.o
[ 68%] Building CXX object CMakeFiles/Display.dir/src/Utils/Math.cpp.o
[ 71%] Building CXX object CMakeFiles/Display.dir/src/Utils/MeshICP.cpp.o
[ 74%] Building CXX object CMakeFiles/Display.dir/src/Utils/OctreeNew.cpp.o
[ 77%] Building CXX object CMakeFiles/Display.dir/src/Utils/QuadTree.cpp.o
[ 80%] Building CXX object CMakeFiles/Display.dir/src/Utils/SegmentQuadTree.cpp.o
[ 82%] Building CXX object CMakeFiles/Display.dir/src/Utils/SimpleRenderer.cpp.o
[ 85%] Building CXX object CMakeFiles/Display.dir/src/Utils/StopWatch.cpp.o
[ 88%] Building CXX object CMakeFiles/Display.dir/src/Utils/Streamer.cpp.o
[ 91%] Building CXX object CMakeFiles/Display.dir/src/Utils/Utils.cpp.o
[ 94%] Building CXX object CMakeFiles/Display.dir/src/DisplayMain.cpp.o
[ 97%] Building CXX object CMakeFiles/Display.dir/src/Reconstructor.cpp.o
[100%] Linking CXX executable Display
[100%] Built target Display
chao@chao:
/Vid2Curve/build$ ./Display

0% 10 20 30 40 50 60 70 80 90 100%
|----|----|----|----|----|----|----|----|----|----|
**段错误

Have you ever encountered this error? If yes, could you please tell me how to fix it?
Thank you very much :)

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

4 participants