Closed TimSousa1 closed 8 months ago
This seems to be a problem in the tiny-cuda-nn setup. I would suggest reporting that issue there https://github.com/NVlabs/tiny-cuda-nn, or testing their bindings in isolation to track down the issue: https://github.com/NVlabs/tiny-cuda-nn#pytorch-extension
I got the one time setup to work on the thousandth try (because im not a programmer/scientist, just very stubborn) - so I hope this will help some people - heres a sketchfab model of bob so you can see I actually managed to get this working
I found that the dmodel environment wasnt working, but found it works in the torch environment we're going to create here.
your GPU must be NVIDIA CUDA enabled - check yours here https://developer.nvidia.com/cuda-gpus - keep the page open as we'll need this later If you do not know what GPU you have go to Start>Device Manager and look under 'display adapters' then compare this to the nvidia cuda gpus page.
ensure you have set this environment variable up:
in the System variables click 'new' and in variable name enter TCNN_CUDA_ARCHITECTURES in variable value enter your GPU compute value - this can be found on NVIDIA https://developer.nvidia.com/cuda-gpus e.g. mine has a Quadro RTX 4000 which has a compute capability of 7.5 - hint - remove the full stop - so 7.5 becomes 75, enter the latter: 75 as the value.
Lets go:
conda create -n torch python=3.6
conda activate torch
pip install numpy
conda install pytorch==1.10.0 torchvision==0.11.0 torchaudio==0.10.0 cudatoolkit=11.3 -c pytorch -c conda-forge
python -c 'import torch; print(torch.rand(2,3).cuda())'
this should return something like:
tensor([[0.5690, 0.3455, 0.4558], [0.7590, 0.6625, 0.0733]], device='cuda:0')
thanks (https://github.com/williamFalcon/pytorch-gpu-install)
python
(this will enable the python interpreter - you can see this is active as the line now starts with >>> then copy the bullet pointed text only
import torch
torch.cuda.is_available()
this should then return True or False - it should return True following this method so far
this should return the number of devices, in my case: 1
0
<torch.cuda.device at 0x7efce0b03be0>
pip install ninja imageio PyOpenGL glfw xatlas gdown
pip install git+https://github.com/NVlabs/nvdiffrast/
pip install --global-option="--no-networks" git+https://github.com/NVlabs/tiny-cuda-nn#subdirectory=bindings/torch
imageio_download_bin freeimage
git clone https://github.com/NVlabs/nvdiffrec
python train.py --config configs/bob.json --display-interval 20
Did it work for you?
This worked for me
Hi, I just made it work to install tiny-cuda-nn follow the instruction here: https://docs.nerf.studio/en/latest/quickstart/installation.html
嗨,我刚刚按照以下说明安装 tiny-cuda-nn https://docs.nerf.studio/en/latest/quickstart/installation.html
Hi, I just made it work to install tiny-cuda-nn follow the instruction here: https://docs.nerf.studio/en/latest/quickstart/installation.html
when I run: pip install --global-option="--no-networks" git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch i get