cxh0519 / threestudio-gaussiandreamer

GaussianDreamer extension of threestudio.
MIT License
42 stars 3 forks source link

Installation seems failed #5

Closed hayoung-jeremy closed 3 months ago

hayoung-jeremy commented 6 months ago

summary

reproduction of the error

installation process as follows :

  1. install gaussian dreamer

    cd custom
    git clone https://github.com/cxh0519/threestudio-gaussiandreamer.git
    cd threestudio-gaussiandreamer
    git clone --recursive https://github.com/ashawkey/diff-gaussian-rasterization
    git clone https://github.com/DSaurus/simple-knn.git
    pip install ./diff-gaussian-rasterization
    pip install ./simple-knn
    
    pip install open3d
    # If you want to export mesh, please install pymeshlab
    pip install pymeshlab
  2. install MVDream

    git clone https://github.com/DSaurus/threestudio-mvdream.git
    cd threestudio-mvdream
    
    # First install xformers (https://github.com/facebookresearch/xformers#installing-xformers)
    # cuda 12.1 version
    pip3 install -U xformers --index-url https://download.pytorch.org/whl/cu121
    
    # Then install other dependencies
    pip install -r requirements.txt
  3. install Shap-e

    git clone https://github.com/DSaurus/threestudio-shap-e
    
    # shap-e + cache directory modification
    git clone https://github.com/DSaurus/shap-e.git
    pip install -e shap-e
  4. install LRM
    git clone https://github.com/cxh0519/threestudio-lrm
    cd threestudio-lrm
    pip install -r requirements.txt

running following commands causes error :

# SD2.1 + shap-e initialize
python launch.py --config custom/threestudio-gaussiandreamer/configs/gaussiandreamer.yaml  --train --gpu 0 system.prompt_processor.prompt="a blue denim jacket" system.geometry.geometry_convert_from="shap-e:a jacket"

# MVDream + lrm initialize
python launch.py --config custom/threestudio-gaussiandreamer/configs/gaussiandreamer_mvdream.yaml  --train --gpu 0 system.prompt_processor.prompt="an astronaut wearing a blue suit" system.geometry.geometry_convert_from="lrm:an astronaut"

the error message :

dreamer@a05e88cc4646:~/threestudio$ python launch.py --config custom/threestudio-gaussiandreamer/configs/gaussiandreamer_mvdream.yaml  --train --gpu 0 system.prompt_processor.prompt="an astronaut wearing a blue suit" system.geometry.geometry_convert_from="lrm:an astronaut"
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/mediapipe_face/mediapipe_face_common.py:7: UserWarning: The module 'mediapipe' is not installed. The package will have limited functionality. Please install it using the command: pip install 'mediapipe'
  warnings.warn(
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/segment_anything/modeling/tiny_vit_sam.py:654: UserWarning: Overwriting tiny_vit_5m_224 in registry with controlnet_aux.segment_anything.modeling.tiny_vit_sam.tiny_vit_5m_224. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/segment_anything/modeling/tiny_vit_sam.py:654: UserWarning: Overwriting tiny_vit_11m_224 in registry with controlnet_aux.segment_anything.modeling.tiny_vit_sam.tiny_vit_11m_224. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/segment_anything/modeling/tiny_vit_sam.py:654: UserWarning: Overwriting tiny_vit_21m_224 in registry with controlnet_aux.segment_anything.modeling.tiny_vit_sam.tiny_vit_21m_224. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/segment_anything/modeling/tiny_vit_sam.py:654: UserWarning: Overwriting tiny_vit_21m_384 in registry with controlnet_aux.segment_anything.modeling.tiny_vit_sam.tiny_vit_21m_384. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
/home/dreamer/.local/lib/python3.10/site-packages/controlnet_aux/segment_anything/modeling/tiny_vit_sam.py:654: UserWarning: Overwriting tiny_vit_21m_512 in registry with controlnet_aux.segment_anything.modeling.tiny_vit_sam.tiny_vit_21m_512. This is because the name being registered conflicts with an existing name. Please check if this is not expected.
  return register_model(fn_wrapper)
Traceback (most recent call last):
  File "/home/dreamer/threestudio/launch.py", line 62, in load_custom_module
    module_spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 883, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/dreamer/threestudio/custom/threestudio-gaussiandreamer/__init__.py", line 17, in <module>
    from .geometry import exporter, gaussian_base, gaussian_io
  File "/home/dreamer/threestudio/custom/threestudio-gaussiandreamer/geometry/gaussian_base.py", line 24, in <module>
    from plyfile import PlyData, PlyElement
ModuleNotFoundError: No module named 'plyfile'

Cannot import custom/threestudio-gaussiandreamer module for custom nodes: No module named 'plyfile'
Traceback (most recent call last):
  File "/home/dreamer/threestudio/launch.py", line 62, in load_custom_module
    module_spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 879, in exec_module
  File "<frozen importlib._bootstrap_external>", line 1016, in get_code
  File "<frozen importlib._bootstrap_external>", line 1073, in get_data
FileNotFoundError: [Errno 2] No such file or directory: '/home/dreamer/threestudio/custom/shap-e/__init__.py'

Cannot import custom/shap-e module for custom nodes: [Errno 2] No such file or directory: '/home/dreamer/threestudio/custom/shap-e/__init__.py'
Traceback (most recent call last):
  File "/home/dreamer/threestudio/launch.py", line 62, in load_custom_module
    module_spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 883, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/dreamer/threestudio/custom/threestudio-lrm/__init__.py", line 15, in <module>
    from . import lrm
  File "/home/dreamer/threestudio/custom/threestudio-lrm/lrm.py", line 5, in <module>
    import rembg
ModuleNotFoundError: No module named 'rembg'

Cannot import custom/threestudio-lrm module for custom nodes: No module named 'rembg'

Import times for custom modules:
   0.0 seconds (IMPORT FAILED): custom/shap-e
   0.0 seconds (IMPORT FAILED): custom/threestudio-gaussiandreamer
   0.1 seconds: custom/threestudio-mvdream
   0.1 seconds (IMPORT FAILED): custom/threestudio-lrm
   0.1 seconds: custom/threestudio-dreamcraft3D
   0.2 seconds: custom/threestudio-shap-e

Seed set to 0
Traceback (most recent call last):
  File "/home/dreamer/threestudio/launch.py", line 301, in <module>
    main(args, extras)
  File "/home/dreamer/threestudio/launch.py", line 169, in main
    system: BaseSystem = threestudio.find(cfg.system_type)(
  File "/home/dreamer/threestudio/threestudio/__init__.py", line 32, in find
    return __modules__[name]
KeyError: 'gaussiandreamer-mvdream-system'
hayoung-jeremy commented 6 months ago

I've installed those libraries from the error log :

pip install mediapipe plyfile rembg

and re-tried, it seems working now, but still showing this error message :

Traceback (most recent call last):
  File "/home/dreamer/threestudio/launch.py", line 62, in load_custom_module
    module_spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 879, in exec_module
  File "<frozen importlib._bootstrap_external>", line 1016, in get_code
  File "<frozen importlib._bootstrap_external>", line 1073, in get_data
FileNotFoundError: [Errno 2] No such file or directory: '/home/dreamer/threestudio/custom/shap-e/__init__.py'

Cannot import custom/shap-e module for custom nodes: [Errno 2] No such file or directory: '/home/dreamer/threestudio/custom/shap-e/__init__.py'
cxh0519 commented 6 months ago

Seems that the error occurs in the installation of Shap-E. Can the code run successfully with LRM? If so, please check the installation of Shap-E.