NVlabs / instant-ngp

Instant neural graphics primitives: lightning fast NeRF and more
https://nvlabs.github.io/instant-ngp
Other
16.05k stars 1.94k forks source link

cmake error when cmake --build build --config RelWithDebInfo -j #1409

Open muximuxi opened 1 year ago

muximuxi commented 1 year ago

[ 87%] Building CUDA object CMakeFiles/ngp.dir/src/testbed_sdf.cu.o [ 87%] Building CXX object CMakeFiles/ngp.dir/src/tinyobj_loader_wrapper.cpp.o [ 89%] Building CUDA object CMakeFiles/ngp.dir/src/triangle_bvh.cu.o /home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: explicit type is missing ("int" assumed)

/home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: qualified name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: expected a ")"

/home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: explicit type is missing ("int" assumed)

/home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: qualified name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/envmap.cuh(67): error: expected a ")"

/home/instant-ngp/include/neural-graphics-primitives/takikawa_encoding.cuh(347): error: namespace "tcnn" has no member "EGradientMode"

/home/instant-ngp/include/neural-graphics-primitives/takikawa_encoding.cuh(347): error: name followed by "::" must be a class or namespace name

/home/instant-ngp/include/neural-graphics-primitives/trainable_buffer.cuh(56): error: namespace "tcnn" has no member "EGradientMode"

/home/instant-ngp/include/neural-graphics-primitives/trainable_buffer.cuh(56): error: name followed by "::" must be a class or namespace name

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(41): error: this declaration has no storage class or type specifier

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(42): error: expected a ";"

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(48): error: this declaration has no storage class or type specifier

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(50): error: expected a ";"

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(92): warning #12-D: parsing restarts here after previous syntax error

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: identifier "TriangleBvh" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: identifier "bvh" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: expected an expression

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: type name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: too many initializer values

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(93): error: expected a ")"

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(95): error: identifier "distance_fun_t" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(99): error: identifier "BoundingBox" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(101): error: identifier "TriangleOctree" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(105): error: identifier "RaysSdfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(105): error: identifier "m_rays_hit" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(106): error: identifier "RaysSdfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(106): error: identifier "m_rays" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(107): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(107): error: identifier "m_n_rays_initialized" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(108): error: identifier "m_trace_shadow_rays" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(109): error: identifier "m_shadow_sharpness" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(110): error: expected a declaration

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(112): error: identifier "RaysSdfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(118): error: expected a declaration

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(135): error: identifier "BoundingBox" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(138): error: identifier "CameraDistortion" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(147): error: identifier "ERenderMode" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(152): error: NerfNetwork is not a template

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(152): error: identifier "precision_t" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(153): error: identifier "BoundingBox" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(154): error: identifier "BoundingBox" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(156): error: identifier "TrainingXForm" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(160): error: identifier "ERenderMode" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(165): error: identifier "ENerfActivation" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(166): error: identifier "ENerfActivation" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(174): error: identifier "RaysNerfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(175): error: identifier "RaysNerfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(183): error: identifier "RaysNerfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(184): error: identifier "RaysNerfSoa" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(185): error: identifier "precision_t" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(196): error: identifier "distance_fun_t" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(236): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(237): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(238): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(239): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(241): error: a type qualifier is not allowed on a nonmember function

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(243): error: incomplete type is not allowed

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(243): error: identifier "CudaRenderBuffer" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(243): error: identifier "render_buffer" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(244): error: expected an expression

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(245): error: expected an expression

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(245): error: identifier "camera_matrix" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(246): error: expected an expression

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(247): error: type name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(247): error: expected a ")"

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(254): error: identifier "distance_fun_t" is undefined

/home/instant-ngp/include/neural-graphics-primitives/testbed.h(255): error: identifier "normals_fun_t" is undefined ...... ...... 3 errors detected in the compilation of "/home/instant-ngp/src/marching_cubes.cu". gmake[2]: [CMakeFiles/ngp.dir/build.make:202: CMakeFiles/ngp.dir/src/marching_cubes.cu.o] Error 1 9 errors detected in the compilation of "/home/instant-ngp/src/nerf_loader.cu". gmake[2]: [CMakeFiles/ngp.dir/build.make:216: CMakeFiles/ngp.dir/src/nerf_loader.cu.o] Error 1 /home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(381): error: namespace "tcnn" has no member "vector_t"

/home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(381): error: type name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(381): error: identifier "rgba_out" is undefined

/home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(391): error: namespace "tcnn" has no member "vector_t"

/home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(391): error: type name is not allowed

/home/instant-ngp/include/neural-graphics-primitives/common_device.cuh(391): error: expected an expression

9 errors detected in the compilation of "/home/instant-ngp/src/common_device.cu". gmake[2]: [CMakeFiles/ngp.dir/build.make:188: CMakeFiles/ngp.dir/src/common_device.cu.o] Error 1 gmake[1]: [CMakeFiles/Makefile2:175: CMakeFiles/ngp.dir/all] Error 2 gmake: *** [Makefile:91: all] Error 2

The compiling environment: ubuntu 22.04 gcc/g++ version:10(or 11) cmake version: 3.22.2 cuda version:11.8 python : 3.10

num-doc commented 1 year ago

I have the same problem as you. Have you solved it?