LGM icon indicating copy to clipboard operation
LGM copied to clipboard

pip install ./diff-gaussian-rasterization failed with no module named 'torch'

Open lciyaya opened this issue 1 year ago • 1 comments

os:windows 11 python: 3.11.9 torch 2.1.0+cu118 torchaudio 2.1.0+cu118 torchvision 0.16.0+cu118 xformers 0.0.22.post4+cu118 (I tried other torch+xformers versions like 2.2.0/2.3.0, they all failed with same error)

full error log : `D:\codes\LGM>pip install ./diff-gaussian-rasterization Processing d:\codes\lgm\diff-gaussian-rasterization Installing build dependencies ... done Getting requirements to build wheel ... error error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> [20 lines of output] Traceback (most recent call last): File "C:\Users\localuser\AppData\Local\Programs\Python\Python311\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 353, in main() File "C:\Users\localuser\AppData\Local\Programs\Python\Python311\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 335, in main json_out['return_val'] = hook(**hook_input['kwargs']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\localuser\AppData\Local\Programs\Python\Python311\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 118, in get_requires_for_build_wheel return hook(config_settings) ^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\localuser\AppData\Local\Temp\pip-build-env-t8laszrt\overlay\Lib\site-packages\setuptools\build_meta.py", line 325, in get_requires_for_build_wheel return self._get_build_requires(config_settings, requirements=['wheel']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\localuser\AppData\Local\Temp\pip-build-env-t8laszrt\overlay\Lib\site-packages\setuptools\build_meta.py", line 295, in _get_build_requires self.run_setup() File "C:\Users\localuser\AppData\Local\Temp\pip-build-env-t8laszrt\overlay\Lib\site-packages\setuptools\build_meta.py", line 487, in run_setup super().run_setup(setup_script=setup_script) File "C:\Users\localuser\AppData\Local\Temp\pip-build-env-t8laszrt\overlay\Lib\site-packages\setuptools\build_meta.py", line 311, in run_setup exec(code, locals()) File "", line 13, in ModuleNotFoundError: No module named 'torch' [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.`

Looks like the similar error with : https://github.com/3DTopia/LGM/issues/12 should I using ubuntu instead of windows11?

lciyaya avatar Jun 18 '24 10:06 lciyaya

try it with

cd /diff-gaussian-rasterization pip install . --no-build-isolation

if like me, your venv module is kinda stupid, you will encounter an error:

error: invalid command 'bdist_wheel'

just run

pip install wheel

and you should be good to go.

Lucalme avatar Aug 20 '24 16:08 Lucalme