Error while trying to install pytorch on pycharm #42353
Labels
module: build
Build system issues
triaged
This issue has been looked at a team member, and triaged and prioritized into an appropriate module
🐛 Bug
Correct way of installation is torch.
This should be removed as it is misleading.
ERROR: Command errored out with exit status 1:
To Reproduce
Steps to reproduce the behavior:
1.Install Pycharm
2.Select Preferences
3.Python interpreter
4.Select +
5. Search Pytorch
6. Click on OK
Expected behavior
Collecting pytorch
Using cached pytorch-1.0.2.tar.gz (689 bytes)
Building wheels for collected packages: pytorch
Building wheel for pytorch (setup.py): started
Building wheel for pytorch (setup.py): finished with status 'error'
Running setup.py clean for pytorch
Failed to build pytorch
Installing collected packages: pytorch
Running setup.py install for pytorch: started
Running setup.py install for pytorch: finished with status 'error'
DEPRECATION: The -b/--build/--build-dir/--build-directory option is deprecated. pip 20.3 will remove support for this functionality. A possible replacement is use the TMPDIR/TEMP/TMP environment variable, possibly combined with --no-clean. You can find discussion regarding this at pypa/pip#8333.
ERROR: Command errored out with exit status 1:
command: /Users/manishrai/venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"'; file='"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pip-wheel-6ne2a5ra
cwd: /private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/
Complete output (5 lines):
Traceback (most recent call last):
File "", line 1, in
File "/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py", line 15, in
raise Exception(message)
Exception: You tried to install "pytorch". The package named for PyTorch is "torch"
ERROR: Failed building wheel for pytorch
DEPRECATION: Could not build wheels for pytorch which do not use PEP 517. pip will fall back to legacy 'setup.py install' for these. pip 21.0 will remove support for this functionality. A possible replacement is to fix the wheel build issue reported above. You can find discussion regarding this at pypa/pip#8368.
ERROR: Command errored out with exit status 1:
command: /Users/manishrai/venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"'; file='"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pip-record-jldeg9tb/install-record.txt --single-version-externally-managed --compile --install-headers /Users/manishrai/venv/include/site/python3.8/pytorch
cwd: /private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/
Complete output (5 lines):
Traceback (most recent call last):
File "", line 1, in
File "/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py", line 11, in
raise Exception(message)
Exception: You tried to install "pytorch". The package named for PyTorch is "torch"
----------------------------------------
ERROR: Command errored out with exit status 1: /Users/manishrai/venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"'; file='"'"'/private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pycharm-packaging/pytorch/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/82/lkm_wx_j42qbx84bs1zq3psm0000gn/T/pip-record-jldeg9tb/install-record.txt --single-version-externally-managed --compile --install-headers /Users/manishrai/venv/include/site/python3.8/pytorch Check the logs for full command output.
Environment
Please copy and paste the output from our
environment collection script
(or fill out the checklist below manually).
You can get the script and run it with:
conda
,pip
, source):Expected Output:
This should be removed as it is misleading.
Correct way of installation is torch.
I did install it and it worked. Just notifying the Pytorch team about the misleading preference on Pycharm. Please check as it damages your credibility.
cc @malfet
The text was updated successfully, but these errors were encountered: