Giter Club home page Giter Club logo

Comments (3)

lianxuepc avatar lianxuepc commented on September 2, 2024

i hava the same problem. Pls have you solved it now?

from mvcontrol.

lianxuepc avatar lianxuepc commented on September 2, 2024

i hava the same problem. Pls have you solved it now?
I solved this issue by manually downloading the model source code on Huggingface

from mvcontrol.

lianxuepc avatar lianxuepc commented on September 2, 2024

I'm encountering multiple issues when running the app_stage1.py script with the provided model. Here is a summary of the bugs:

  1. ValueError: Custom Code Execution Required

While trying to load the lzq49/mvdream-sd21-diffusers model pipeline using MVControlPipeline.from_pretrained, I receive the following error:

bash Copy code ValueError: The repository for lzq49/mvdream-sd21-diffusers contains custom code in unet/unet.py, camera_proj/camera_proj which must be executed to correctly load the model. You can inspect the repository content at https://hf.co/lzq49/mvdream-sd21-diffusers/unet/unet.py, https://hf.co/lzq49/mvdream-sd21-diffusers/camera_proj/camera_proj.py. Please pass the argument trust_remote_code=True to allow custom code to be run. Suggested Fix: Adding the trust_remote_code=True argument to the pipeline loading functions resolves the issue. Here is an example modification in app_stage1.py:

python Copy code from pipeline_mvcontrol import load_mvcontrol_pipeline

pipe_mvcontrol = load_mvcontrol_pipeline( "lzq49/mvdream-sd21-diffusers", revision="main", torch_dtype=torch.float16, trust_remote_code=True # Add this argument here ) Or, directly with MVControlPipeline.from_pretrained:

python Copy code from diffusers import MVControlPipeline

pipe_mvcontrol = MVControlPipeline.from_pretrained( "lzq49/mvdream-sd21-diffusers", torch_dtype=torch.float16, trust_remote_code=True # Add this argument here ) 2. Deprecation Warnings:

During execution, the following warnings are displayed:

vbnet Copy code /home/dubaiprince/miniconda3/envs/mvcontrol/lib/python3.9/site-packages/diffusers/utils/outputs.py:63: UserWarning: torch.utils._pytree._register_pytree_node is deprecated. Please use torch.utils._pytree.register_pytree_node instead. torch.utils._pytree._register_pytree_node( /home/dubaiprince/miniconda3/envs/mvcontrol/lib/python3.9/site-packages/huggingface_hub/file_download.py:1132: FutureWarning: resume_download is deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, use force_download=True. warnings.warn( Suggested Fixes:

Update the usage of _register_pytree_node in diffusers/utils/outputs.py: python Copy code torch.utils._pytree.register_pytree_node( # Replace _register_pytree_node Update the resume_download usage in huggingface_hub/file_download.py: python Copy code force_download=True # Instead of resume_download 3. xFormers Warning:

A warning related to xFormers is also raised:

arduino Copy code /home/dubaiprince/Projects/MVControl-threestudio/extern/lgm/attention.py:22: UserWarning: xFormers is available (Attention) warnings.warn("xFormers is available (Attention)") Suggested Fix: Ensure that xFormers is compatible with the current environment by aligning the versions of Python, PyTorch, and CUDA.

Reproduction Steps: Run the command python app_stage1.py big --resume pretrained/model_fp16.safetensors --condition_type $condition_type Observe the error and warnings. Environment: OS: Ubuntu 20.04 Python Version: 3.9.19 Torch Version: 2.3.0 Torchvision Version: 0.17.1+cu118 Let me know if you need more details, or if I can assist with testing any fixes.

I solved this issue by manually downloading the model source code on Huggingface

from mvcontrol.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.