jianweiguo / local3Ddescriptorlearning

Deep learning local descriptors for 3D surface shapes
9 stars 5 forks source link

Couldn't compile the gigen.cpp #4

Open ccCamila opened 5 years ago

ccCamila commented 5 years ago

Thank you so much for your tutorial. I'm trying to use it but face the problems.

  1. May I ask is this only used for windows system? I'm using it in Ubuntu.
  2. Would you help me with the second part? Build cpp solution: this code is to generate geometry images. You can run this step in your local desktop.

I couldn't finish the compile part and face the problem. Here is the detail: The CMakLists.txt in local3Ddescriptorlearning-master/3dDescriptorLearning/cpp_geometry_images_generation include_directories( OpenMesh-6.3/src/OpenMesh ) # OpenMesh head files directory. I'm not sure is this the correct directories for OpenMesh head files in ubuntu. link_directories( OpenMesh-6.3/Release/Build/lib ) # OpenMesh lib files directory.

When I compile in 3dDescriptorLearning/cpp_geometry_images_generation/build I use i586-mingw32msvc-g++ -o gigen ../src/gigen.cpp -I ../include/ There are so many errors.

In file included from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/Mesh_C.h:1: error: stray ‘\357’ in program
../include/Mesh_C.h:1: error: stray ‘\273’ in program
../include/Mesh_C.h:1: error: stray ‘\277’ in program
In file included from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/Mesh_C.h:18:38: error: OpenMesh/Core/IO/MeshIO.hh: No such file or directory
../include/Mesh_C.h:19:54: error: OpenMesh/Core/Mesh/TriMesh_ArrayKernelT.hh: No such file or directory
In file included from ../include/Mesh_C.h:21,
                 from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/libcompcur.h:14:22: error: mclmcrrt.h: No such file or directory
../include/libcompcur.h:15:25: error: mclcppclass.h: No such file or directory
In file included from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/Mesh_C.h:22:20: error: mclmcr.h: No such file or directory
../include/Mesh_C.h:23:20: error: matrix.h: No such file or directory
In file included from ../src/gigen.cpp:9:
../include/Mesh_C.h:1: error: stray ‘\357’ in program
../include/Mesh_C.h:1: error: stray ‘\273’ in program
../include/Mesh_C.h:1: error: stray ‘\277’ in program
In file included from ../include/GPC.h:11,
                 from ../src/gigen.cpp:10:
../include/Mesh_C.h:1: error: stray ‘\357’ in program
../include/Mesh_C.h:1: error: stray ‘\273’ in program
../include/Mesh_C.h:1: error: stray ‘\277’ in program
In file included from ../include/GPC.h:13,
                 from ../src/gigen.cpp:10:
../include/nanoflann.hpp:50:17: error: array: No such file or directory
In file included from ../include/utils.h:13,
                 from ../src/gigen.cpp:11:
../include/dirent.h:1157:20: warning: no newline at end of file
In file included from ../src/gigen.cpp:11:
../include/utils.h:161:18: warning: no newline at end of file
In file included from ../include/GI.h:12,
                 from ../src/gigen.cpp:12:
../include/utils.h:161:18: warning: no newline at end of file
../src/gigen.cpp:15:18: error: thread: No such file or directory
../src/gigen.cpp:18:17: error: mutex: No such file or directory
In file included from ../src/gigen.cpp:19:
../include/dirent.h:1157:20: warning: no newline at end of file
../src/gigen.cpp:22:20: error: mclmcr.h: No such file or directory
../src/gigen.cpp:23:20: error: matrix.h: No such file or directory
../src/gigen.cpp:24:25: error: mclcppclass.h: No such file or directory
In file included from ../include/Mesh_C.h:20,
                 from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/Vector3.h: In member function ‘std::string GIGen::Vector3<real_t>::to_string() const’:
../include/Vector3.h:130: error: no match for ‘operator<<’ in ‘oss << "x: "’
../include/Vector3.h:131: error: invalid use of incomplete type ‘struct std::ostringstream’
/usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/include/c++/iosfwd:79: error: declaration of ‘struct std::ostringstream’
../include/Vector3.h: In constructor ‘GIGen::Rot_mat<real_t>::Rot_mat(const real_t&, const real_t&, const real_t&, const real_t&)’:
../include/Vector3.h:163: error: expected unqualified-id before ‘&&’ token
../include/Vector3.h:167: error: expected unqualified-id before ‘&&’ token
../include/Vector3.h:168: error: expected unqualified-id before ‘&&’ token
../include/Vector3.h:169: error: expected unqualified-id before ‘&&’ token
../include/Vector3.h:171: error: ‘x’ was not declared in this scope
../include/Vector3.h:172: error: ‘y’ was not declared in this scope
../include/Vector3.h:172: error: ‘z’ was not declared in this scope
In file included from ../include/Mesh_C.h:21,
                 from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/libcompcur.h: At global scope:
../include/libcompcur.h:61: error: expected initializer before ‘libcompcurInitializeWithHandlers’
../include/libcompcur.h:66: error: expected initializer before ‘libcompcurInitialize’
../include/libcompcur.h:69: error: expected initializer before ‘libcompcurTerminate’
../include/libcompcur.h:74: error: expected initializer before ‘libcompcurPrintStackTrace’
../include/libcompcur.h:77: error: expected initializer before ‘mlxCompute_curvature’
../include/libcompcur.h:110: error: expected initializer before ‘compute_curvature’
In file included from ../include/Generator.h:16,
                 from ../src/gigen.cpp:8:
../include/Mesh_C.h:34: error: ‘OpenMesh’ has not been declared
../include/Mesh_C.h:34: error: expected `{' before ‘DefaultTraits’
../include/Mesh_C.h:34: error: function definition does not declare parameters
../include/Mesh_C.h:39: error: expected nested-name-specifier before ‘Point’
../include/Mesh_C.h:39: error: ‘Point’ has not been declared
../include/Mesh_C.h:39: error: expected `;' before ‘=’ token
../include/Mesh_C.h:39: error: expected unqualified-id before ‘=’ token
../include/Mesh_C.h:43: error: ‘OpenMesh’ has not been declared
../include/Mesh_C.h:43: error: ISO C++ forbids declaration of ‘VPropHandleT’ with no type
../include/Mesh_C.h:43: error: expected ‘;’ before ‘<’ token
../include/Mesh_C.h:44: error: ‘OpenMesh’ has not been declared
../include/Mesh_C.h:44: error: ISO C++ forbids declaration of ‘VPropHandleT’ with no type
../include/Mesh_C.h:44: error: expected ‘;’ before ‘<’ token
../include/Mesh_C.h:45: error: ‘OpenMesh’ has not been declared
../include/Mesh_C.h:45: error: ISO C++ forbids declaration of ‘VPropHandleT’ with no type
../include/Mesh_C.h:45: error: expected ‘;’ before ‘<’ token
../include/Mesh_C.h:49: error: ‘OpenMesh’ has not been declared
../include/Mesh_C.h:49: error: expected `{' before ‘TriMesh_ArrayKernelT’
../include/Mesh_C.h:49: error: expected initializer before ‘<’ token
In file included from /usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/../../../../i586-mingw32msvc/include/windef.h:253,
                 from /usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/../../../../i586-mingw32msvc/include/windows.h:48,
                 from ../include/dirent.h:19,
                 from ../include/utils.h:13,
                 from ../src/gigen.cpp:11:
/usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/../../../../i586-mingw32msvc/include/winnt.h:2422: error: expected `}' before end of line
/usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/../../../../i586-mingw32msvc/include/winnt.h:2422: error: expected declaration before end of line

It should be wrong with my command. I want to compile cpp in ubuntu, so I use mingw32. But I could not compile it. There must be something wrong with this.

The config.ini in local3Ddescriptorlearning-master/3dDescriptorLearning/cpp_geometry_images_generationis this:

mesh_dir=local3Ddescriptorlearning-master/3dDescriptorLearning/dataset/MPI-FAUST/training
gi_dir=local3Ddescriptorlearning-master/3dDescriptorLearning/gi
kpi_dir=local3Ddescriptorlearning-master/3dDescriptorLearning/keypoints_faust256

Thank you so much for your help.

jianweiguo commented 5 years ago

Hi, We only test the code of cpp solution in Windows. Maybe it is easier for you to generate geometry images in Windows. Then you copy the generated geometry images into ubuntu for training.

ccCamila commented 5 years ago

Hi, We only test the code of cpp solution in Windows. Maybe it is easier for you to generate geometry images in Windows. Then you copy the generated geometry images into ubuntu for training.

OK! Thank you so much! It's great.

AssignmentKiller commented 5 years ago

Hi, We only test the code of cpp solution in Windows. Maybe it is easier for you to generate geometry images in Windows. Then you copy the generated geometry images into ubuntu for training.

OK! Thank you so much! It's great.

image May I ask which openmesh should I download? static or dll? Is 8.0 ok? Is there any special requirement?

kayleeliyx commented 5 years ago

image

Here is a tip when compiling it. generate config, the second one, you should choose x64 or win32 in cmake-gui. I choose x64 and then I can finally build it. It's quite confusing if you don't know it.

Here is the result: image

kayleeliyx commented 5 years ago

Hi! Would you please give me some right screenshot because I couldn't use GIGen.exe and the error looks like this: image

It seems the arrangement for the dataset is not right. How did you run this step in windows?

Here are my folders:

image

Here is the ini: image

The folder "registritions" is downloaded from FAUST website: image

gi/faust_256p and keypoints_faust256.kpi are two empty folders.

Thank you in advance!