ShichenLiu / SoftRas

Project page of paper "Soft Rasterizer: A Differentiable Renderer for Image-based 3D Reasoning"
MIT License
1.24k stars 156 forks source link

I got the error :No module soft_renderer.cuda.load_textures ,when I run the command :CUDA_VISIBLE_DEVICES=0 python examples/demo_render.py #100

Open luogyu7 opened 2 years ago

luogyu7 commented 2 years ago

There are serveral images in the attachment that illustrate the program execution progress and the errors. Firstly, I create the virtual environment with anaconda, 4.12.0 version . And I follow the Readme file guide , run : conda install pytorch==1.6 installed the pytorch , the version recorded in the readme file.

run: python setup.py install install the required modules for the program : the result show in Fig1. 1 Fig1 .The terminal result after running command "python setup.py install"

After I installed the matplotlib module , run: CUDA_VISIBLE_DEVICES=0 python examples/demo_render.py Show that files missing, in Fig 2.

2 Fig2 The error after running command "CUDA_VISIBLE_DEVICES=0 python examples/demo_render.py"

try to run: bash examples/recon/download_dataset.sh & CUDA_VISIBLE_DEVICES=0 python examples/recon/train.py -eid recon I can get the terminal result show in Fig 3. 3Fig 3 The terminal result after running command "bash examples/recon/download_dataset.sh & CUDA_VISIBLE_DEVICES=0 python examples/recon/train.py -eid recon" I try to search fold , file directory /SoftRas/Soft_render/. 4

There is no such document "soft_renderer.cuda.load_textures" in the folder. DId I do any steps wrong? Could you point out what went wrong? Looking forward to your answers , thanks you very much.

luogyu7 commented 2 years ago

supplementary instruction: I install the cuda version 10.1,Satisfies the readme file Introductions. Looking forward to answer. Thanks a million.

ecmjohnson commented 2 years ago

Hey @luogyu7, I can suggest you try moving into the examples directory before running the demo_render.py script. That is (after installation) from the repo root:

cd examples
CUDA_VISIBLE_DEVICES=0 python demo_render.py

As mentioned in #76 (specifically here), when trying to import soft_renderer from the repo root it picks up the file in the repo rather than the installation. This confused me for a while and I hope it helps!