-
Notifications
You must be signed in to change notification settings - Fork 107
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
RuntimeError: Error compiling objects for extension #19
Comments
一样的问题 |
@xiaoli-ai @xiaobiaozhu 请问您解决了么? |
@lmw0320 |
请问是修改哪个文件下的部分呢?主要是我用python3.8 pytorch7.1成功编译了,但是python3.7和pytorch1.7.1一直编不过,但是环境又要求是python3.7 |
./pointnet2/src/ 里的那些.cpp .h .cu文件。替换掉这些文件中所有使用AT_CHECK和THCState_getCurrentStream(state)的地方就好。 |
谢谢回复!我打开这些源码后发现代码的都是已经修改好了的,不过我发现我用的是pytorch1.7,我换回1.6就能编译了。
版本太新了😂
…---Original---
From: "youkangGG"<[email protected]>
Date: Wed, Jan 6, 2021 10:13 AM
To: "sshaoshuai/Pointnet2.PyTorch"<[email protected]>;
Cc: "大哥大哥你还好吗"<[email protected]>;"Comment"<[email protected]>;
Subject: Re: [sshaoshuai/Pointnet2.PyTorch] RuntimeError: Error compiling objects for extension (#19)
请问是修改哪个文件下的部分呢?主要是我用python3.8 pytorch7.1成功编译了,但是python3.7和pytorch1.7.1一直编不过,但是环境又要求是python3.7
./pointnet2/src/ 里的那些C和C++文件。替换掉这些文件中所有使用AT_CHECK and THCState_getCurrentStream(state)的地方就好。
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
你好你的那个问题是如何解决我的有点不明白 |
您好,我在配置SE-SSD环境也遇到了这个问题,按照您说的内容,修改这些文件,发现AT_CHECK需要修改,THCState_getCurrentStream(state)已经都是at::cuda::getCurrentCUDAStream(),但是修改后测试还是报了相同的错误 |
您好,我的环境是:
ubuntu16.04
torch1.5
cuda10.1
我的编译一直不能正常通过,报错信息如下:
[9/9] /usr/local/cuda-10.1/bin/nvcc -I/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/include -I/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/include/TH -I/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/include/THC -I/usr/local/cuda-10.1/include -I/home/psdz/anaconda3/envs/pytorch/include/python3.8 -c -c '/home/psdz/文档/Pointnet2.PyTorch/pointnet2/src/sampling_gpu.cu' -o '/home/psdz/文档/Pointnet2.PyTorch/pointnet2/build/temp.linux-x86_64-3.8/src/sampling_gpu.o' -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options '-fPIC' -O2 -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=pointnet2_cuda -D_GLIBCXX_USE_CXX11_ABI=0 -gencode=arch=compute_75,code=sm_75 -std=c++14
ninja: build stopped: subcommand failed.
Traceback (most recent call last):
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/utils/cpp_extension.py", line 1395, in _run_ninja_build
subprocess.run(
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/subprocess.py", line 512, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "setup.py", line 4, in
setup(
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/init.py", line 161, in setup
return distutils.core.setup(**attrs)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/core.py", line 148, in setup
dist.run_commands()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/install.py", line 67, in run
self.do_egg_install()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/install.py", line 109, in do_egg_install
self.run_command('bdist_egg')
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/bdist_egg.py", line 173, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/bdist_egg.py", line 159, in call_command
self.run_command(cmdname)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/install_lib.py", line 11, in run
self.build()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/command/install_lib.py", line 107, in build
self.run_command('build_ext')
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/build_ext.py", line 87, in run
_build_ext.run(self)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/Cython/Distutils/old_build_ext.py", line 186, in run
_build_ext.build_ext.run(self)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/command/build_ext.py", line 340, in run
self.build_extensions()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/utils/cpp_extension.py", line 580, in build_extensions
build_ext.build_extensions(self)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/Cython/Distutils/old_build_ext.py", line 195, in build_extensions
_build_ext.build_ext.build_extensions(self)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/command/build_ext.py", line 449, in build_extensions
self._build_extensions_serial()
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/command/build_ext.py", line 474, in _build_extensions_serial
self.build_extension(ext)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/setuptools/command/build_ext.py", line 208, in build_extension
_build_ext.build_extension(self, ext)
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/distutils/command/build_ext.py", line 528, in build_extension
objects = self.compiler.compile(sources,
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/utils/cpp_extension.py", line 414, in unix_wrap_ninja_compile
_write_ninja_file_and_compile_objects(
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/utils/cpp_extension.py", line 1135, in _write_ninja_file_and_compile_objects
_run_ninja_build(
File "/home/psdz/anaconda3/envs/pytorch/lib/python3.8/site-packages/torch/utils/cpp_extension.py", line 1413, in _run_ninja_build
raise RuntimeError(message)
RuntimeError: Error compiling objects for extension
请指导一下,谢谢您
The text was updated successfully, but these errors were encountered: