QingyongHu / RandLA-Net

🔥RandLA-Net in Tensorflow (CVPR 2020, Oral & IEEE TPAMI 2021)
Other
1.27k stars 316 forks source link

关于环境配置的问题:sh compile_op.sh #117

Open YAOmmeng opened 3 years ago

YAOmmeng commented 3 years ago

胡博士你好,我最近也在跑您的神经网络,但是在进行环境配置sh compile_op.sh的时候,出现了下面的问题:

running install running build running build_ext cythoning knn.pyx to knn.cpp /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /home/nvidia/RandLA-Net-master2/utils/nearest_neighbors/knn.pyx tree = Parsing.p_module(s, pxd, full_module_name) building 'nearest_neighbors' extension creating build creating build/temp.linux-x86_64-3.5 gcc -pthread -B /home/nvidia/anaconda3/envs/randlanet2/compiler_compat -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I./ -I/home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include -I/home/nvidia/anaconda3/envs/randlanet2/include/python3.5m -c knn.cpp -o build/temp.linux-x86_64-3.5/knn.o -std=c++11 -fopenmp cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ In file included from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:0, from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/ndarrayobject.h:12, from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/arrayobject.h:4, from knn.cpp:612: /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]

warning "Using deprecated NumPy API, disable it with " \

^ gcc -pthread -B /home/nvidia/anaconda3/envs/randlanet2/compilercompat -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I./ -I/home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include -I/home/nvidia/anaconda3/envs/randlanet2/include/python3.5m -c knn.cxx -o build/temp.linux-x8664-3.5/knn.o -std=c++11 -fopenmp cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ In file included from knn_.cxx:6:0: KDTreeTableAdaptor.h: In instantiation of ‘KDTreeTableAdaptor<TableType, num_t, DIM, Distance, IndexType>::KDTreeTableAdaptor(size_t, size_t, const TableType, int) [with TableType = float; num_t = float; int DIM = -1; Distance = nanoflann::metric_L2; IndexType = long unsigned int; sizet = long unsigned int]’: knn.cxx:28:40: required from here KDTreeTableAdaptor.h:131:19: warning: ‘KDTreeTableAdaptor<float, float>::m_data’ will be initialized after [-Wreorder] const TableType m_data; ^ KDTreeTableAdaptor.h:129:9: warning: ‘size_t KDTreeTableAdaptor<float, float>::dim’ [-Wreorder] size_t dim; ^ KDTreeTableAdaptor.h:134:2: warning: when initialized here [-Wreorder] KDTreeTableAdaptor(const size_t npts, const size_t dim, const TableType* mat, const int leaf_max_size = 10) : m_data(mat), dim(dim), npts(npts) ^ creating build/lib.linux-x86_64-3.5 g++ -pthread -shared -L/home/nvidia/anaconda3/envs/randlanet2/lib -B /home/nvidia/anaconda3/envs/randlanet2/compiler_compat -Wl,-rpath=/home/nvidia/anaconda3/envs/randlanet2/lib,--no-as-needed build/temp.linux-x86_64-3.5/knn.o build/temp.linux-x8664-3.5/knn.o -o build/lib.linux-x86_64-3.5/nearest_neighbors.cpython-35m-x86_64-linux-gnu.so -std=c++11 -fopenmp running install_lib creating lib creating lib/python copying build/lib.linux-x86_64-3.5/nearest_neighbors.cpython-35m-x86_64-linux-gnu.so -> ./lib/python running install_egg_info Writing ./lib/python/KNN_NanoFLANN-0.0.0-py3.5.egg-info running build_ext building 'grid_subsampling' extension Warning: Can't read registry to find the necessutils.nearest_neighbors.lib.python.nearest_neighborsary compiler setting Make sure that Python modules winreg, win32api or win32con are installed. C compiler: gcc -pthread -B /home/nvidia/anaconda3/envs/randlanet2/compiler_compat -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC

creating build creating build/temp.linux-x86_64-3.5 creating build/temp.linux-x86_64-3.5/cpp_wrappers creating build/temp.linux-x86_64-3.5/cpp_wrappers/cpp_utils creating build/temp.linux-x86_64-3.5/cpp_wrappers/cpp_utils/cloud creating build/temp.linux-x86_64-3.5/grid_subsampling compile options: '-I/home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include -I/home/nvidia/anaconda3/envs/randlanet2/include/python3.5m -c' extra options: '-std=c++11 -D_GLIBCXX_USE_CXX11_ABI=0' gcc: grid_subsampling/grid_subsampling.cpp gcc: ../cpp_utils/cloud/cloud.cpp gcc: wrapper.cpp cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ In file included from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:0, from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/ndarrayobject.h:12, from /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/arrayobject.h:4, from wrapper.cpp:2: /home/nvidia/anaconda3/envs/randlanet2/lib/python3.5/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]

warning "Using deprecated NumPy API, disable it with " \

^ wrapper.cpp: In function ‘PyObject grid_subsampling_compute(PyObject, PyObject, PyObject)’: wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char’ [-Wwrite-strings] static char kwlist[] = {"points", "features", "classes", "sampleDl", "method", "verbose", NULL }; ^ wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char’ [-Wwrite-strings] wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char’ [-Wwrite-strings] wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char’ [-Wwrite-strings] wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char’ [-Wwrite-strings] wrapper.cpp:70:98: warning: ISO C++ forbids converting a string constant to ‘char*’ [-Wwrite-strings] grid_subsampling/grid_subsampling.cpp: In function ‘void grid_subsampling(std::vector&, std::vector&, std::vector&, std::vector&, std::vector&, std::vector&, float, int)’: grid_subsampling/grid_subsampling.cpp:99:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (int i = 0; i < ldim; i++) ^ g++ -pthread -shared -L/home/nvidia/anaconda3/envs/randlanet2/lib -B /home/nvidia/anaconda3/envs/randlanet2/compiler_compat -Wl,-rpath=/home/nvidia/anaconda3/envs/randlanet2/lib,--no-as-needed build/temp.linux-x86_64-3.5/cpp_wrappers/cpp_utils/cloud/cloud.o build/temp.linux-x86_64-3.5/grid_subsampling/grid_subsampling.o build/temp.linux-x86_64-3.5/wrapper.o -o /home/nvidia/RandLA-Net-master2/utils/cpp_wrappers/cpp_subsampling/grid_subsampling.cpython-35m-x86_64-linux-gnu.so

我理解的这一步是通过Cython将knn.pyx 编译为 knn.cpp,但是出现了上述的警告,之后在utils/nearest_neighbors/lib/python/下找不到nearest_neighbors这个文件。请问是我环境配置的有问题吗还是其他的什么,我也是按照您之前的环境去配置的,还请您解答

zeng-ziyin commented 3 years ago

我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗?

liumengyaoo commented 3 years ago

请问您解决了吗

liumengyaoo commented 3 years ago

我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗?

请问您解决了吗?

YAOmmeng commented 3 years ago

已经解决了,感谢您的回复

------------------ 原始邮件 ------------------ 发件人: "QingyongHu/RandLA-Net" @.>; 发送时间: 2021年4月13日(星期二) 下午2:54 @.>; @.**@.>; 主题: Re: [QingyongHu/RandLA-Net] 关于环境配置的问题:sh compile_op.sh (#117)

请问您解决了吗

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

YAOmmeng commented 3 years ago

按照作者提供的步骤建立虚拟环境即可 ------------------ 原始邮件 ------------------ 发件人: "QingyongHu/RandLA-Net" @.>; 发送时间: 2021年4月13日(星期二) 下午2:55 @.>; @.**@.>; 主题: Re: [QingyongHu/RandLA-Net] 关于环境配置的问题:sh compile_op.sh (#117)

我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗?

请问您解决了吗?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

zeng-ziyin commented 3 years ago

我已经解决了,解决方法是换了一台服务器,重装系统之后重新配置驱动和环境。感谢您提供的代码。

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2021年4月13日(星期二) 下午2:55 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [QingyongHu/RandLA-Net] 关于环境配置的问题:sh compile_op.sh (#117)

我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗?

请问您解决了吗?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

liumengyaoo commented 3 years ago

按照作者提供的步骤建立虚拟环境即可 ------------------ 原始邮件 ------------------ 发件人: "QingyongHu/RandLA-Net" @.>; 发送时间: 2021年4月13日(星期二) 下午2:55 @.>; @.**@.>; 主题: Re: [QingyongHu/RandLA-Net] 关于环境配置的问题:sh compile_op.sh (#117) 我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗? 请问您解决了吗? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

谢谢您我试试

liumengyaoo commented 3 years ago

我已经解决了,解决方法是换了一台服务器,重装系统之后重新配置驱动和环境。感谢您提供的代码。 ------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2021年4月13日(星期二) 下午2:55 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [QingyongHu/RandLA-Net] 关于环境配置的问题:sh compile_op.sh (#117) 我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗? 请问您解决了吗? — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

谢谢您

Chengyuelan commented 2 years ago

我也遇到了同样的问题,还没有解决方案,请问你这边解决了吗?

@

@zeng-ziyin 我想请教你一下,你跑的RandLA-Net算法是严格按照作者所提供的驱动版本来的吗,可不可以用更高的版本呢

RaywoodWEt commented 2 years ago

可能是目录有问题,编译的时候改成绝对路径试试

w-yasuo commented 1 year ago

@RaywoodWEt

可能是目录有问题,编译的时候改成绝对路径试试

您好,麻烦您能具体说一下怎么改路径么,我尝了一下都不太好用,一直提示 1660035131731

guan2000910 commented 9 months ago

您好,请问这个问题如何解决的?

zhangwanyao commented 4 months ago

你好,这个邮件我看不到,怎么解决的啊,我的是gcc编译找不到 sh compile_op.sh running install running build running build_ext building 'nearest_neighbors' extension gcc -pthread -B /home/zwy/anaconda3/envs/tensorflow-2.6/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -I./ -I/home/zwy/anaconda3/envs/tensorflow-2.6/lib/python3.8/site-packages/numpy/core/include -I/home/zwy/anaconda3/envs/tensorflow-2.6/include/python3.8 -c knn.cxx -o build/temp.linux-x86_64-3.8/knn.o -std=c++11 -fopenmp gcc: error: knn.cxx: 没有那个文件或目录 gcc: fatal error: no input files compilation terminated. error: command 'gcc' failed with exit status 4 running build_ext

lucasi-max commented 4 months ago

你好,这个邮件我看不到,怎么解决的啊,我的是gcc编译找不到 sh compile_op.sh running install running build running build_ext building 'nearest_neighbors' extension gcc -pthread -B /home/zwy/anaconda3/envs/tensorflow-2.6/compiler_compat -wno-unused-result -wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -I./ -I/home/zwy/anaconda3/envs/tensorflow-2.6/lib/python3.8/site-packages/numpy/core/include -I/home/zwy/anaconda3/envs/tensorflow-2.6/include/python3.8 -c knn.cxx -o build/temp.linux-x86_64-3.8/knn.o -std=c++11 -fopenmp gcc:错误:knn.cxx:没有那个文件或目录 gcc:致命错误:没有输入文件编译终止。错误:命令“gcc”失败,退出状态 4 正在运行build_ext

@zhangwanyao 你好,我也是这个错误,请问你解决了吗?

zhangwanyao commented 4 months ago

你好,这个邮件我看不到,怎么解决的啊,我的是gcc编译找不到 sh compile_op.sh running install running build running build_ext building 'nearest_neighbors' extension gcc -pthread -B /home/zwy/anaconda3/envs/tensorflow-2.6/compiler_compat -wno-unused-result -wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -I./ -I/home/zwy/anaconda3/envs/tensorflow-2.6/lib/python3.8/site-packages/numpy/core/include -I/home/zwy/anaconda3/envs/tensorflow-2.6/include/python3.8 -c knn.cxx -o build/temp.linux-x86_64-3.8/knn.o -std=c++11 -fopenmp gcc:错误:knn.cxx:没有那个文件或目录 gcc:致命错误:没有输入文件编译终止。错误:命令“gcc”失败,退出状态 4 正在运行build_ext

@zhangwanyao 你好,我也是这个错误,请问你解决了吗?

解决了,你需要降一下你的gcc和g++版本,还有编译的时候需要GLIBC_2.32编译动态库grid_subsampling.cpython-36m-x86_64-linux-gnu.so

lucasi-max commented 4 months ago

g++ -pthread -shared -L/home/nvidia/anaconda3/envs/randlanet2/lib -B /home/nvidia/anaconda3/envs/randlanet2/compiler_compat -Wl,-rpath=/home/nvidia/anaconda3/envs/randlanet2/lib,--no-as-needed build/temp.linux-x86_64-3.5/cpp_wrappers/cpp_utils/cloud/cloud.o build/temp.linux-x86_64-3.5/grid_subsampling/grid_subsampling.o build/temp.linux-x86_64-3.5/wrapper.o -o /home/nvidia/RandLA-Net-master2/utils/cpp_wrappers/cpp_subsampling/grid_subsampling.cpython-35m-x86_64-linux-gnu.so

谢谢您,我试试

Serendipity-luck commented 3 months ago

你好,这个邮件我看不到,怎么解决的啊,我的是gcc编译找不到 sh compile_op.sh running install running build running build_ext building 'nearest_neighbors' extension gcc -pthread -B /home/zwy/anaconda3/envs/tensorflow-2.6/compiler_compat -wno-unused-result -wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -O2 -isystem /home/zwy/anaconda3/envs/tensorflow-2.6/include -fPIC -I./ -I/home/zwy/anaconda3/envs/tensorflow-2.6/lib/python3.8/site-packages/numpy/core/include -I/home/zwy/anaconda3/envs/tensorflow-2.6/include/python3.8 -c knn.cxx -o build/temp.linux-x86_64-3.8/knn.o -std=c++11 -fopenmp gcc:错误:knn.cxx:没有那个文件或目录 gcc:致命错误:没有输入文件编译终止。错误:命令“gcc”失败,退出状态 4 正在运行build_ext

@zhangwanyao 你好,我也是这个错误,请问你解决了吗?

解决了,你需要降一下你的gcc和g++版本,还有编译的时候需要GLIBC_2.32编译动态库grid_subsampling.cpython-36m-x86_64-linux-gnu.so

你好,目前我从gcc-10 g++-8降到了gcc-8和g++-8,依然出现这个错误,请问您除了降低版本外,还做了什么额外的操作吗?