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

python setup.py build develop pytorch-1.0 branch, IndexError: list index out of range #681

Open
sdoerr1 opened this issue Oct 22, 2019 · 1 comment

Comments

@sdoerr1
Copy link

sdoerr1 commented Oct 22, 2019

I'm currently on Windows 10 x64, with python=3.6, pytorch=1.2, and cuda 10.1

After trying to install the package using the pytorch-1.0 branch, I am finding the following errors:

python setup.py build develop running build running build_py running build_ext C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\torch\utils\cpp_extension.py:189: UserWarning: Error checking compiler version for cl: [WinError 2] The system cannot find the file specified warnings.warn('Error checking compiler version for {}: {}'.format(compiler, error)) building 'model._C' extension Traceback (most recent call last): File "setup.py", line 66, in <module> cmdclass={"build_ext": torch.utils.cpp_extension.BuildExtension}, File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\setuptools\__init__.py", line 145, in setup return distutils.core.setup(**attrs) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\core.py", line 148, in setup dist.run_commands() File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\dist.py", line 955, in run_commands self.run_command(cmd) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\dist.py", line 974, in run_command cmd_obj.run() File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\command\build.py", line 135, in run self.run_command(cmd_name) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\cmd.py", line 313, in run_command self.distribution.run_command(command) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\dist.py", line 974, in run_command cmd_obj.run() File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\setuptools\command\build_ext.py", line 84, in run _build_ext.run(self) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\Cython\Distutils\old_build_ext.py", line 186, in run _build_ext.build_ext.run(self) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\command\build_ext.py", line 339, in run self.build_extensions() File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\torch\utils\cpp_extension.py", line 350, in build_extensions build_ext.build_extensions(self) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\Cython\Distutils\old_build_ext.py", line 194, in build_extensions self.build_extension(ext) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\site-packages\setuptools\command\build_ext.py", line 205, in build_extension _build_ext.build_extension(self, ext) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\command\build_ext.py", line 558, in build_extension target_lang=language) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\ccompiler.py", line 717, in link_shared_object extra_preargs, extra_postargs, build_temp, target_lang) File "C:\Users\sdoerr1\AppData\Local\Continuum\anaconda3\envs\cookiecutter.screw_detector\lib\distutils\_msvccompiler.py", line 501, in link build_temp = os.path.dirname(objects[0]) IndexError: list index out of range

Looking back to the README, I might have to compile the modules myself since I am using python 3.6. Could this be the reason for the errors with installation? If so, can someone point me to some instructions for compiling these modules myself, as I'm not from a CS background?

@sdoerr1 sdoerr1 changed the title python setup.py build develop pytorch-1.0 branch issue python setup.py build develop pytorch-1.0 branch, IndexError: list index out of range Oct 22, 2019
@Chris310826
Copy link

I have the same problem. Have you solved it

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

2 participants