open-mmlab / PIA

[CVPR 2024] PIA, your Personalized Image Animator. Animate your images by text prompt, combing with Dreambooth, achieving stunning videos. PIA,你的个性化图像动画生成器,利用文本提示将图像变为奇妙的动画
https://pi-animator.github.io/
Apache License 2.0
913 stars 75 forks source link

运行 demo 的时候报错 #46

Open JinesD opened 4 months ago

JinesD commented 4 months ago

我在运行 webui demo 的时候,报出一下错误: Start Load Models... loaded temporal unet's pretrained weights from models/StableDiffusion/unet ... missing keys: 560; unexpected keys: 0; Temporal Module Parameters: 417.1376 M

Begin loading DreamBooth >>> Prefix in loaded VAE checkpoint: {'post_quant_conv', 'decoder', 'quant_conv', 'encoder'} <<< Loaded DreamBooth <<< Begin loading LoRA >>> Traceback (most recent call last): File "/home//Documents/PIA/animatediff/utils/convert_lora_safetensor_to_diffusers.py", line 117, in convert_lora_model_level curr_layer = curr_layer.getattr(temp_name) File "/home//anaconda3/envs/pia/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1709, in getattr raise AttributeError(f"'{type(self).name}' object has no attribute '{name}'") AttributeError: 'CLIPTextModel' object has no attribute 'cond_stage_model'

运行环境如下: (pia) ➜ PIA git:(main) conda list packages in environment at /home/*/anaconda3/envs/pia:

Name Version Build Channel _libgcc_mutex 0.1 main
_openmp_mutex 5.1 1_gnu
accelerate 0.31.0 pypi_0 pypi aiofiles 23.2.1 pypi_0 pypi altair 5.3.0 pypi_0 pypi annotated-types 0.7.0 pypi_0 pypi antlr4-python3-runtime 4.9.3 pypi_0 pypi anyio 4.4.0 pypi_0 pypi attrs 23.2.0 pypi_0 pypi beautifulsoup4 4.12.3 pypi_0 pypi blas 1.0 mkl
brotli-python 1.0.9 py310h6a678d5_8
bzip2 1.0.8 h5eee18b_6
ca-certificates 2024.3.11 h06a4308_0
certifi 2024.6.2 py310h06a4308_0
charset-normalizer 2.0.4 pyhd3eb1b0_0
click 8.1.7 pypi_0 pypi contourpy 1.2.1 pypi_0 pypi cuda-cudart 11.8.89 0 nvidia cuda-cupti 11.8.87 0 nvidia cuda-libraries 11.8.0 0 nvidia cuda-nvrtc 11.8.89 0 nvidia cuda-nvtx 11.8.86 0 nvidia cuda-runtime 11.8.0 0 nvidia cuda-version 12.5 3 nvidia cycler 0.12.1 pypi_0 pypi decorator 4.4.2 pypi_0 pypi decord 0.6.0 pypi_0 pypi diffusers 0.24.0 pypi_0 pypi dnspython 2.6.1 pypi_0 pypi docker-pycreds 0.4.0 pypi_0 pypi einops 0.8.0 pypi_0 pypi email-validator 2.2.0 pypi_0 pypi exceptiongroup 1.2.1 pypi_0 pypi fastapi 0.111.0 pypi_0 pypi fastapi-cli 0.0.4 pypi_0 pypi ffmpeg 4.3 hf484d3e_0 pytorch ffmpy 0.3.2 pypi_0 pypi filelock 3.13.1 py310h06a4308_0
fonttools 4.53.0 pypi_0 pypi freetype 2.12.1 h4a9f257_0
fsspec 2024.6.0 pypi_0 pypi gdown 5.2.0 pypi_0 pypi git-lfs 3.5.1 h06a4308_0
gitdb 4.0.11 pypi_0 pypi gitpython 3.1.43 pypi_0 pypi gmp 6.2.1 h295c915_3
gmpy2 2.1.2 py310heeb90bb_0
gnutls 3.6.15 he1e5248_0
gradio 4.36.1 pypi_0 pypi gradio-client 1.0.1 pypi_0 pypi h11 0.14.0 pypi_0 pypi httpcore 1.0.5 pypi_0 pypi httptools 0.6.1 pypi_0 pypi httpx 0.27.0 pypi_0 pypi huggingface-hub 0.23.4 pypi_0 pypi idna 3.7 py310h06a4308_0
imageio 2.33.1 pypi_0 pypi imageio-ffmpeg 0.5.1 pypi_0 pypi importlib-metadata 7.2.1 pypi_0 pypi importlib-resources 6.4.0 pypi_0 pypi intel-openmp 2023.1.0 hdb19cb5_46306
jinja2 3.1.4 py310h06a4308_0
jpeg 9e h5eee18b_1
jsonschema 4.22.0 pypi_0 pypi jsonschema-specifications 2023.12.1 pypi_0 pypi kiwisolver 1.4.5 pypi_0 pypi lame 3.100 h7b6447c_0
lcms2 2.12 h3be6417_0
ld_impl_linux-64 2.38 h1181459_1
lerc 3.0 h295c915_0
libcublas 11.11.3.6 0 nvidia libcufft 10.9.0.58 0 nvidia libcufile 1.10.0.4 0 nvidia libcurand 10.3.6.39 0 nvidia libcusolver 11.4.1.48 0 nvidia libcusparse 11.7.5.86 0 nvidia libdeflate 1.17 h5eee18b_1
libffi 3.4.4 h6a678d5_1
libgcc-ng 11.2.0 h1234567_1
libgomp 11.2.0 h1234567_1
libiconv 1.16 h5eee18b_3
libidn2 2.3.4 h5eee18b_0
libnpp 11.8.0.86 0 nvidia libnvjpeg 11.9.0.86 0 nvidia libpng 1.6.39 h5eee18b_0
libstdcxx-ng 11.2.0 h1234567_1
libtasn1 4.19.0 h5eee18b_0
libtiff 4.5.1 h6a678d5_0
libunistring 0.9.10 h27cfd23_0
libuuid 1.41.5 h5eee18b_0
libwebp-base 1.3.2 h5eee18b_0
lz4-c 1.9.4 h6a678d5_1
markdown-it-py 3.0.0 pypi_0 pypi markupsafe 2.1.3 py310h5eee18b_0
matplotlib 3.9.0 pypi_0 pypi mdurl 0.1.2 pypi_0 pypi mkl 2023.1.0 h213fc3f_46344
mkl-service 2.4.0 py310h5eee18b_1
mkl_fft 1.3.8 py310h5eee18b_0
mkl_random 1.2.4 py310hdb19cb5_0
moviepy 1.0.3 pypi_0 pypi mpc 1.1.0 h10f8cd9_1
mpfr 4.0.2 hb69a4c5_1
mpmath 1.3.0 py310h06a4308_0
ncurses 6.4 h6a678d5_0
nettle 3.7.3 hbbd107a_1
networkx 3.2.1 py310h06a4308_0
numpy 1.26.4 py310h5f9d8c6_0
numpy-base 1.26.4 py310hb5e798b_0
nvidia-cublas-cu12 12.1.3.1 pypi_0 pypi nvidia-cuda-cupti-cu12 12.1.105 pypi_0 pypi nvidia-cuda-nvrtc-cu12 12.1.105 pypi_0 pypi nvidia-cuda-runtime-cu12 12.1.105 pypi_0 pypi nvidia-cudnn-cu12 8.9.2.26 pypi_0 pypi nvidia-cufft-cu12 11.0.2.54 pypi_0 pypi nvidia-curand-cu12 10.3.2.106 pypi_0 pypi nvidia-cusolver-cu12 11.4.5.107 pypi_0 pypi nvidia-cusparse-cu12 12.1.0.106 pypi_0 pypi nvidia-nccl-cu12 2.20.5 pypi_0 pypi nvidia-nvjitlink-cu12 12.5.40 pypi_0 pypi nvidia-nvtx-cu12 12.1.105 pypi_0 pypi omegaconf 2.3.0 pypi_0 pypi opencv-python 4.10.0.84 pypi_0 pypi openh264 2.1.1 h4ff587b_0
openjpeg 2.4.0 h3ad879b_0
openssl 3.0.14 h5eee18b_0
orjson 3.10.5 pypi_0 pypi packaging 24.1 pypi_0 pypi pandas 2.2.2 pypi_0 pypi pillow 10.3.0 py310h5eee18b_0
pip 24.0 py310h06a4308_0
platformdirs 4.2.2 pypi_0 pypi proglog 0.1.10 pypi_0 pypi protobuf 5.27.1 pypi_0 pypi psutil 6.0.0 pypi_0 pypi pydantic 2.7.4 pypi_0 pypi pydantic-core 2.18.4 pypi_0 pypi pydub 0.25.1 pypi_0 pypi pygments 2.18.0 pypi_0 pypi pyparsing 3.1.2 pypi_0 pypi pysocks 1.7.1 py310h06a4308_0
python 3.10.14 h955ad1f_1
python-dateutil 2.9.0.post0 pypi_0 pypi python-dotenv 1.0.1 pypi_0 pypi python-multipart 0.0.9 pypi_0 pypi pytorch-cuda 11.8 h7e8668a_5 pytorch pytorch-mutex 1.0 cuda pytorch pytz 2024.1 pypi_0 pypi pyyaml 6.0.1 pypi_0 pypi readline 8.2 h5eee18b_0
referencing 0.35.1 pypi_0 pypi regex 2024.5.15 pypi_0 pypi requests 2.32.2 py310h06a4308_0
rich 13.7.1 pypi_0 pypi rpds-py 0.18.1 pypi_0 pypi ruff 0.4.10 pypi_0 pypi safetensors 0.4.3 pypi_0 pypi semantic-version 2.10.0 pypi_0 pypi sentry-sdk 2.6.0 pypi_0 pypi setproctitle 1.3.3 pypi_0 pypi setuptools 69.5.1 py310h06a4308_0
shellingham 1.5.4 pypi_0 pypi six 1.16.0 pypi_0 pypi smmap 5.0.1 pypi_0 pypi sniffio 1.3.1 pypi_0 pypi soupsieve 2.5 pypi_0 pypi sqlite 3.45.3 h5eee18b_0
starlette 0.37.2 pypi_0 pypi sympy 1.12 py310h06a4308_0
tbb 2021.8.0 hdb19cb5_0
tk 8.6.14 h39e8969_0
tokenizers 0.13.3 pypi_0 pypi tomlkit 0.12.0 pypi_0 pypi toolz 0.12.1 pypi_0 pypi torch 2.3.1+cu121 pypi_0 pypi torchaudio 2.3.1+cu121 pypi_0 pypi torchvision 0.15.0 py310_cu118 pytorch tqdm 4.66.4 pypi_0 pypi transformers 4.25.1 pypi_0 pypi triton 2.3.1 pypi_0 pypi typer 0.12.3 pypi_0 pypi typing_extensions 4.11.0 py310h06a4308_0
tzdata 2024.1 pypi_0 pypi ujson 5.10.0 pypi_0 pypi urllib3 2.2.2 py310h06a4308_0
uvicorn 0.30.1 pypi_0 pypi uvloop 0.19.0 pypi_0 pypi wandb 0.17.2 pypi_0 pypi watchfiles 0.22.0 pypi_0 pypi websockets 11.0.3 pypi_0 pypi wheel 0.43.0 py310h06a4308_0
xformers 0.0.26.post1 pypi_0 pypi xz 5.4.6 h5eee18b_1
zipp 3.19.2 pypi_0 pypi zlib 1.2.13 h5eee18b_1
zstd 1.5.5 hc292b87_2

请问,需要怎么解决,谢谢。

mamianshusheng commented 4 months ago

Maybe the version of the sd that you downloaded is wrong. AttributeError usually occurs when the package or environment version is downloaded incorrectly