ValueError: too many values to unpack (expected 2)

#255
by ChaseXuu - opened

I tried to use the example code to load the model. However, an error occurred

ValueError Traceback (most recent call last)
Cell In[45], line 8
4 model_id = "CompVis/stable-diffusion-v1-4"
5 device = "cuda"
----> 8 pipe = StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.float16)
9 pipe = pipe.to(device)
11 prompt = "a photo of an astronaut riding a horse on mars"

File /home/chixu/anaconda3/envs/p2p/lib/python3.8/site-packages/diffusers/pipeline_utils.py:316, in DiffusionPipeline.from_pretrained(cls, pretrained_model_name_or_path, **kwargs)
313 expected_modules = set(inspect.signature(pipeline_class.init).parameters.keys())
314 passed_class_obj = {k: kwargs.pop(k) for k in expected_modules if k in kwargs}
--> 316 init_dict, _ = pipeline_class.extract_init_dict(config_dict, **kwargs)
318 init_kwargs = {}
320 # import it here to avoid circular import

ValueError: too many values to unpack (expected 2)

Sign up or log in to comment