`No module named 'ldm'` error occurs in `scripts/eval.sh`
Closed this issue · 2 comments
TMats commented
Thank you very much for making the codebase public!
I tried to evaluate public checkpoints following README, and I encountered the error below.
➜ workspace bash scripts/eval.sh GNFACTOR_BC released
[2023-12-27 11:06:50,025][root][INFO] - Using env device cuda:0.
[2023-12-27 11:06:50,073][root][INFO] - Evaluating seed 0.
Traceback (most recent call last):
File "/root/workspace/GNFactor/eval.py", line 260, in <module>
main()
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/main.py", line 32, in decorated_main
_run_hydra(
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/_internal/utils.py", line 346, in _run_hydra
run_and_report(
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/_internal/utils.py", line 201, in run_and_report
raise ex
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/_internal/utils.py", line 198, in run_and_report
return func()
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/_internal/utils.py", line 347, in <lambda>
lambda: hydra.run(
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/_internal/hydra.py", line 107, in run
return run_job(
File "/root/.pyenv/versions/3.9.18/lib/python3.9/site-packages/hydra/core/utils.py", line 128, in run_job
ret.return_value = task_function(task_cfg)
File "/root/workspace/GNFactor/eval.py", line 250, in main
eval_seed(train_cfg,
File "/root/workspace/GNFactor/eval.py", line 47, in eval_seed
from agents import gnfactor_bc
File "/root/workspace/GNFactor/agents/gnfactor_bc/__init__.py", line 1, in <module>
import agents.gnfactor_bc.launch_utils
File "/root/workspace/GNFactor/agents/gnfactor_bc/launch_utils.py", line 23, in <module>
from agents.gnfactor_bc.qattention_gnfactor_bc_agent import QAttentionPerActBCAgent
File "/root/workspace/GNFactor/agents/gnfactor_bc/qattention_gnfactor_bc_agent.py", line 22, in <module>
from agents.gnfactor_bc.neural_rendering import NeuralRenderer
File "/root/workspace/GNFactor/agents/gnfactor_bc/neural_rendering.py", line 11, in <module>
from agents.gnfactor_bc.models_embed import GeneralizableNeRFEmbedNet
File "/root/workspace/GNFactor/agents/gnfactor_bc/models_embed.py", line 6, in <module>
from agents.gnfactor_bc.resnetfc import ResnetFC
File "/root/workspace/GNFactor/agents/gnfactor_bc/resnetfc.py", line 8, in <module>
from .attention import Visual3DLangTransformer
File "/root/workspace/GNFactor/agents/gnfactor_bc/attention.py", line 12, in <module>
from ldm.modules.diffusionmodules.util import checkpoint
ModuleNotFoundError: No module named 'ldm'
This error is happened here,
I think this line is to load checkpoints using utils of latent-diffusion
Do we also need to install latent-diffusion, which is not instructed in INSTALL.md?
Thanks in advance,
YanjieZe commented
Yes, could you try this? pip install stable-diffusion-sdkit==2.1.3
TMats commented
Thanks! It worked!
PS: I'm creating a docker environment for GNFactor. https://github.com/TMats/GNFactor/tree/feature/docker/docker