Open SongChaotian opened 1 year ago
In the Inference stage of Single-Subject Generation, I executed the following command and reported the following error. I would like to ask how to solve it:
python inference.py --pretrained_model_name_or_path="runwayml/stable-diffusion-v1-5" --spectral_shifts_ckpt="output_models/checkpoint-500/spectral_shifts.safetensors" --prompt="A picture of a sks dog in a bucket" --scheduler_type="dpm_solver++" --num_inference_steps=25 --num_images_per_prompt=2
device: cuda Resumed from output_models/checkpoint-500/spectral_shifts.safetensors Traceback (most recent call last): File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 142, in main() File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 73, in main text_encoder = load_text_encoder( File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 45, in load_text_encoder text_encoder = load_text_encoder_for_svdiff( File "/home/songchaotian/sct/Apps/svdiff-pytorch/svdiff_pytorch/utils.py", line 137, in load_text_encoder_for_svdiff set_module_tensor_to_device(model, key, param_device, value=f.get_tensor(key), dtype=torch_dtype) File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/accelerate/utils/modeling.py", line 269, in set_module_tensor_to_device new_module = getattr(module, split) File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1614, in getattr raise AttributeError("'{}' object has no attribute '{}'".format( AttributeError: 'CLIPTextModel' object has no attribute 'conv_in'
Hi, I have the same error, have you solved it ?
@SongChaotian
In the Inference stage of Single-Subject Generation, I executed the following command and reported the following error. I would like to ask how to solve it: python inference.py --pretrained_model_name_or_path="runwayml/stable-diffusion-v1-5" --spectral_shifts_ckpt="output_models/checkpoint-500/spectral_shifts.safetensors" --prompt="A picture of a sks dog in a bucket" --scheduler_type="dpm_solver++" --num_inference_steps=25 --num_images_per_prompt=2 device: cuda Resumed from output_models/checkpoint-500/spectral_shifts.safetensors Traceback (most recent call last): File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 142, in main() File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 73, in main text_encoder = load_text_encoder( File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 45, in load_text_encoder text_encoder = load_text_encoder_for_svdiff( File "/home/songchaotian/sct/Apps/svdiff-pytorch/svdiff_pytorch/utils.py", line 137, in load_text_encoder_for_svdiff set_module_tensor_to_device(model, key, param_device, value=f.get_tensor(key), dtype=torch_dtype) File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/accelerate/utils/modeling.py", line 269, in set_module_tensor_to_device new_module = getattr(module, split) File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1614, in getattr raise AttributeError("'{}' object has no attribute '{}'".format( AttributeError: 'CLIPTextModel' object has no attribute 'conv_in'
Hi, I have the same error, have you solved it ?
Hi, I get the same error, did you find the solution?
In the Inference stage of Single-Subject Generation, I executed the following command and reported the following error. I would like to ask how to solve it:
python inference.py \ --pretrained_model_name_or_path="runwayml/stable-diffusion-v1-5" \ --spectral_shifts_ckpt="output_models/checkpoint-500/spectral_shifts.safetensors" \ --prompt="A picture of a sks dog in a bucket" \ --scheduler_type="dpm_solver++" \ --num_inference_steps=25 \ --num_images_per_prompt=2
device: cuda Resumed from output_models/checkpoint-500/spectral_shifts.safetensors Traceback (most recent call last): File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 142, in
main()
File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 73, in main
text_encoder = load_text_encoder(
File "/home/songchaotian/sct/Apps/svdiff-pytorch/inference.py", line 45, in load_text_encoder
text_encoder = load_text_encoder_for_svdiff(
File "/home/songchaotian/sct/Apps/svdiff-pytorch/svdiff_pytorch/utils.py", line 137, in load_text_encoder_for_svdiff
set_module_tensor_to_device(model, key, param_device, value=f.get_tensor(key), dtype=torch_dtype)
File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/accelerate/utils/modeling.py", line 269, in set_module_tensor_to_device
new_module = getattr(module, split)
File "/home/songchaotian/.conda/envs/svdiff/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1614, in getattr
raise AttributeError("'{}' object has no attribute '{}'".format(
AttributeError: 'CLIPTextModel' object has no attribute 'conv_in'