mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-11-15 20:33:59 +08:00
Update to allow pytorch (and functorch) 1.13.1 (#1390)
* Update pytorch (and functorch) to 1.13.1 Note that for existing installations, the following is recommended due to complications with older versions of functorch: - `pip uninstall torch torchvision functorch` - install the correct pytorch 1.13.1 version for your CUDA installation from https://pytorch.org/get-started/locally/ but add functorch to the command -- for example, Windows CUDA 11.7 would be `pip3 install torch torchvision functorch--extra-index-url https://download.pytorch.org/whl/cu117` - reinstall nerfstudio e.g. `pip install -e .` from the source directory * Update installation.md * Allow 1.13.1, don't force * pytorch 1.12.1 and 1.13.1 * Update README.md * Update installation.md
This commit is contained in:
1 parent
9808ebbcb8
commit
9c5423f181
3 files changed
+45
-8
No files matched your search
@@ -95,13 +95,25 @@ python -m pip install --upgrade pip
|
||||
|
||||
### Dependencies
|
||||
|
||||
Install pytorch with CUDA (this repo has been tested with CUDA 11.3) and [tiny-cuda-nn](https://github.com/NVlabs/tiny-cuda-nn)
|
||||
Install pytorch with CUDA (this repo has been tested with CUDA 11.3 and CUDA 11.7) and [tiny-cuda-nn](https://github.com/NVlabs/tiny-cuda-nn)
|
||||
|
||||
For CUDA 11.3:
|
||||
|
||||
```bash
|
||||
pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 -f https://download.pytorch.org/whl/torch_stable.html
|
||||
pip install git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
|
||||
```
|
||||
|
||||
For CUDA 11.7:
|
||||
|
||||
```bash
|
||||
pip install torch torchvision functorch --extra-index-url https://download.pytorch.org/whl/cu117
|
||||
pip install git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
|
||||
```
|
||||
|
||||
See [Dependencies](https://github.com/nerfstudio-project/nerfstudio/blob/main/docs/quickstart/installation.md#dependencies)
|
||||
in the Installation documentation for more.
|
||||
|
||||
### Installing nerfstudio
|
||||
|
||||
Easy option:
|
||||
|
||||
@@ -17,12 +17,38 @@ python -m pip install --upgrade pip
|
||||
|
||||
## Dependencies
|
||||
|
||||
Install pytorch with CUDA (this repo has been tested with CUDA 11.3) and [tiny-cuda-nn](https://github.com/NVlabs/tiny-cuda-nn)
|
||||
(pytorch)=
|
||||
### pytorch
|
||||
|
||||
Either pytorch 1.12.1 (with CUDA up to 11.3) or 1.13.1 (with CUDA 11.6/7/8) can be used.
|
||||
|
||||
- To install 1.12.1 with CUDA 11.3:
|
||||
|
||||
```bash
|
||||
pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 -f https://download.pytorch.org/whl/torch_stable.html
|
||||
pip install git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
|
||||
```
|
||||
|
||||
- To install 1.13.1 with CUDA 11.7:
|
||||
|
||||
Note that if a pytorch version prior to 1.13 is installed,
|
||||
it should be uninstalled first to avoid upgrade issues (e.g. with functorch)
|
||||
|
||||
```bash
|
||||
pip uninstall torch torchvision functorch
|
||||
```
|
||||
|
||||
Install pytorch 1.13.1 with CUDA (this repo has been tested with CUDA 11.7.1) and [tiny-cuda-nn](https://github.com/NVlabs/tiny-cuda-nn)
|
||||
|
||||
```bash
|
||||
pip install torch torchvision functorch --extra-index-url https://download.pytorch.org/whl/cu117
|
||||
```
|
||||
|
||||
### tinycudann
|
||||
|
||||
After pytorch, install the torch bindings for tinycudann:
|
||||
|
||||
```bash
|
||||
pip install git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
|
||||
```
|
||||
|
||||
## Installing nerfstudio
|
||||
@@ -134,9 +160,8 @@ While installing tiny-cuda, you run into: `The detected CUDA version mismatches
|
||||
|
||||
**Solution**:
|
||||
|
||||
```
|
||||
pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 -f https://download.pytorch.org/whl/torch_stable.html
|
||||
```
|
||||
Reinstall pytorch with the correct CUDA version.
|
||||
See [pytorch](pytorch) under Dependencies, above.
|
||||
|
||||
<br />
|
||||
|
||||
|
||||
+2
-2
@@ -22,7 +22,7 @@ dependencies = [
|
||||
"tyro>=0.3.31",
|
||||
"gdown>=4.6.0",
|
||||
"ninja>=1.10",
|
||||
"functorch==0.2.1",
|
||||
"functorch>=0.2.1",
|
||||
"h5py>=2.9.0",
|
||||
"imageio>=2.21.1",
|
||||
'importlib-metadata>=6.0.0; python_version < "3.10"',
|
||||
@@ -45,7 +45,7 @@ dependencies = [
|
||||
"rich>=12.5.1",
|
||||
"scikit-image>=0.19.3",
|
||||
"tensorboard==2.9.0",
|
||||
"torch==1.12.1",
|
||||
"torch>=1.12.1",
|
||||
"torchmetrics[image]>=0.9.3",
|
||||
"torchtyping>=0.1.4",
|
||||
"torchvision>=0.13.0",
|
||||
|
||||
Reference in new issue
Block a user