IssueRaiser

Instructions for installing PyTorch

<!-- Hi there! Thank you for discovering and submitting an issue with our documentation. Before you submit this; let's make sure of a few things. Please make sure the following boxes are ticked if they are correct. If not, please try and fulfill these first. --> <!-- Checked checkbox should look like this: [x] --> - [x] I have searched the [issues](https://github.com/python-poetry/poetry/issues) of this repo and believe that this is not a duplicate. ## Issue <!-- Now feel free to write your issue, but please be descriptive! Thanks again 🙌 ❤️ --> As mentioned in issue https://github.com/python-poetry/poetry/issues/4231 there is some confusion around installing PyTorch with CUDA but it is now somewhat resolved. It still requires a few steps, and all options have pretty serious flaws. Below are two options that 'worked' for me, on Poetry version `1.2.0`. # Option 1 - wheel URLs for a specific platform * You will need to pick the specific wheels you want. These are listed here: https://download.pytorch.org/whl/torch_stable.html. E.g. if you want CUDA 11.6, Python 3.10 and Windows, search that page for `cu116-cp310-cp310-win_amd64.whl` to see the matches for `torch`, `torchaudio` and `torchvision` * In your `pyproject.toml` file add the URLs like: ```toml [tool.poetry.dependencies] python = "^3.10" numpy = "^1.23.2" torch = { url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp310-cp310-win_amd64.whl"} torchaudio = { url = "https://download.pytorch.

Posted by davidgilbertson on Sep 5, 2022, 8:59 AM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.2,500 issues0 comments

github (Software)

Instructions for installing PyTorch

davidgilbertsonSep 5, 2022, 8:59 AM

<!-- Hi there! Thank you for discovering and submitting an issue with our documentation. Before you submit this; let's make sure of a few things. Please make sure the following boxes are ticked if they are correct. If not, please try and fulfill these first. --> <!-- Checked checkbox should look like this: [x] --> - [x] I have searched the [issues](https://github.com/python-poetry/poetry/issues) of this repo and believe that this is not a duplicate. ## Issue <!-- Now feel free to write your issue, but please be descriptive! Thanks again 🙌 ❤️ --> As mentioned in issue https://github.com/python-poetry/poetry/issues/4231 there is some confusion around installing PyTorch with CUDA but it is now somewhat resolved. It still requires a few steps, and all options have pretty serious flaws. Below are two options that 'worked' for me, on Poetry version `1.2.0`. # Option 1 - wheel URLs for a specific platform * You will need to pick the specific wheels you want. These are listed here: https://download.pytorch.org/whl/torch_stable.html. E.g. if you want CUDA 11.6, Python 3.10 and Windows, search that page for `cu116-cp310-cp310-win_amd64.whl` to see the matches for `torch`, `torchaudio` and `torchvision` * In your `pyproject.toml` file add the URLs like: ```toml [tool.poetry.dependencies] python = "^3.10" numpy = "^1.23.2" torch = { url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp310-cp310-win_amd64.whl"} torchaudio = { url = "https://download.pytorch.

Comments (0)

No comments yet. Start the discussion.

Comment on this issue