ShivamShrirao / diffusers

🤗 Diffusers: State-of-the-art diffusion models for image and audio generation in PyTorch
https://huggingface.co/docs/diffusers
Apache License 2.0
1.89k stars 506 forks source link

Error no file named model_index.json #115

Open AVoidRunner opened 1 year ago

AVoidRunner commented 1 year ago

Describe the bug

This is with the Imagic example using Google Colab

When I run the Inferense on Collab, I just started getting this error. Do you know how I can fix this? It happens regardless of if I select to save the weights in "Settings and run" to the google drive.

Here's the error output:


OSError Traceback (most recent call last) in 8 9 scheduler = DDIMScheduler(beta_start=0.00085, beta_end=0.012, beta_schedule="scaled_linear", clip_sample=False, set_alpha_to_one=False) ---> 10 pipe = StableDiffusionPipeline.from_pretrained(model_path, scheduler=scheduler, torch_dtype=torch.float16).to("cuda") 11 target_embeddings = torch.load(os.path.join(model_path, "target_embeddings.pt")).to("cuda") 12 optimized_embeddings = torch.load(os.path.join(model_path, "optimized_embeddings.pt")).to("cuda")

1 frames /usr/local/lib/python3.7/dist-packages/diffusers/configuration_utils.py in get_config_dict(cls, pretrained_model_name_or_path, **kwargs) 221 else: 222 raise EnvironmentError( --> 223 f"Error no file named {cls.config_name} found in directory {pretrained_model_name_or_path}." 224 ) 225 else:

OSError: Error no file named model_index.json found in directory /content/stable_diffusion_weights/imagic.

Reproduction

No response

Logs

No response

System Info

Google Colab link