forked from pytorch/rl
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Doc] Document undefined symbol error with torch version < 1.13 (pyto…
…rch#707) * Create VERSIONING_ISSUES.md * Update README.md * Update README.md * Update VERSIONING_ISSUES.md * Update VERSIONING_ISSUES.md * Update README.md * Update VERSIONING_ISSUES.md * Update VERSIONING_ISSUES.md * Update VERSIONING_ISSUES.md
- Loading branch information
Showing
2 changed files
with
26 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Versioning Issues | ||
|
||
## Pytorch version | ||
This issue is related to https://github.com/pytorch/rl/issues/689. Using PyTorch versions <1.13 and installing stable package leads to undefined symbol errors. For example: | ||
``` | ||
ImportError: /usr/local/lib/python3.7/dist-packages/torchrl/_torchrl.so: undefined symbol: _ZN8pybind116detail11type_casterIN2at6TensorEvE4loadENS_6handleEb | ||
``` | ||
|
||
### How to reproduce | ||
1. Create an Colab Notebook (at 24/11/2022 Colab enviroment has Python 3.7 and Pytorch 1.12 installed by default). | ||
2. ``` !pip install torchrl ``` | ||
3. ``` import torchrl ``` | ||
|
||
In Colab you can solve the issue by running: | ||
``` | ||
!pip3 install torch --extra-index-url https://download.pytorch.org/whl/cpu -U | ||
``` | ||
before the ```!pip install torchrl``` command. This will install the latest pytorch. Instructions can be found [here](https://pytorch.org/get-started/locally/). | ||
|
||
### Workarounds | ||
There are two workarounds to this issue | ||
1. Install/upgrade to the latest pytorch release before installing torchrl. | ||
2. If you need to use a previous pytorch relase: Install functorch version related to your torch distribution: e.g. ``` pip install functorch==0.2.0 ``` and install library from source ``` pip install git+https://github.com/pytorch/rl@<lib_version_here> ```. |