Repository Not Found for url: https://huggingface.co/api/models/stabilityai/stable-diffusion-2-base

The assignment of module 2: visualizing AI food quality inspection. In section 9.1 -optional exercises: text-to-image generation. It refers to the stable-diffusion-2-base. It says to use model from local (.models) cache directory. But I don’t see this folder from the left panel of the website. So it caused the code to fetch from Huggingface and it failed.

img = generate_sd_image(“A mango with a small hole made by a worm in the middle.”, “Fresh, intact.”, 42, 50)

Couldn’t connect to the Hub: 401 Client Error. (Request ID: Root=1-69403fce-041f6f871aa81d362ff0ce28;7bfd9a13-3a4f-4aae-99ea-1cb14afedad8)

Repository Not Found for url: https://huggingface.co/api/models/stabilityai/stable-diffusion-2-base.
Please make sure you specified the correct repo_id and repo_type.
If you are trying to access a private or gated repo, make sure you are authenticated. For more details, see Quickstart
Invalid username or password..
Will try to load from local cache.

I checked on Huggingface, seems the link is not there anymore.

It looks like this thread is misfiled. It is not in PyTorch Course 1 M3, but PyTorch Course 3 Module 2. I will change the title.

Are you running this notebook on the DLAI website or on your own local computer? I have not gotten to this exercise yet, but in looking through the notebook I do not see any references to the huggingface website. They have included the files locally, but if you copy the assignment to your own computer you need to copy all the associated files.

Hi,

I was running this on DLAI website.

It is the assignment of module 2: visualizing AI food quality inspection. In section 9.1 -optional exercises: text-to-image generation. It refers to the stable-diffusion-2-base. It says to use model from local (.models) cache directory. But I don’t see this folder from the left panel of the website. So it caused the code to fetch from Huggingface and it failed.

Thanks,
Xiaofeng

@xzhang14 I am also getting the same error. Were you able to resolve this issue?

@xzhang14

is your error same as this error :backhand_index_pointing_down:t2:

The model: stable-diffusion-2-base doesn’t exist anymore in the Higgingface hub. I think the notebook needs to be updated.

Hi! The model actually now needs you to be logged with the huggingface-cli. I’ve fixed it by adding a local copy. You will need to restore to the previous version to make the folder to appear:

Please download the files before doing it as everything will be wiped out and replaced by a brand new copy.

Then you should see a folder called “models”. If this folder is present, everything should run smoothly.

Let me know if this fix the issue.

Cheers,
Lucas

1 Like