# TypeError when loading pipeline

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftypeerror-when-loading-pipeline%2F35023%3E%5C
**Category:** Beginners\
**Created:** [March 29, 2023, 3:08pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftypeerror-when-loading-pipeline%2F35023 "2023-03-29T15:08:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AmasDeHousses](https://avatars.discourse-cdn.com/v4/letter/a/919ad9/32.png) [@AmasDeHousses](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FAmasDeHousses)%5C
**Post date:** [March 29, 2023, 3:08pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftypeerror-when-loading-pipeline%2F35023%2F1 "2023-03-29T15:08:04Z")

</div>

Hello everyone,

I’m trying to follow these instructions : [Load pipelines, models, and schedulers](https://huggingface.co/docs/diffusers/using-diffusers/loading)

But I get this :

> > > from diffusers import DiffusionPipeline  
> > > pipeline = DiffusionPipeline.from\_pretrained(“runwayml/stable-diffusion-v1-5”)  
> > > Fetching 19 files: 100%|███████████████████████████████████████████████████████████████████████| 19/19 [00:00\<?, ?it/s]  
> > > The config attributes {‘clip\_sample’: False} were passed to PNDMScheduler, but are not expected and will be ignored. Please verify your scheduler\_config.json configuration file.  
> > > Traceback (most recent call last):  
> > > File “”, line 1, in   
> > > File “C:\Users\win101user\AppData\Local\Env01\Lib\site-packages\diffusers\pipeline\_utils.py”, line 455, in from\_pretrained  
> > > load\_method = getattr(class\_obj, load\_method\_name)  
> > > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
> > > TypeError: attribute name must be string, not ‘NoneType’

It looks like an error in the code but I don’t know much…

Any help would be appreciated, thanks !

---

<div class="post-metadata">

**Author:** ![mapama247](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/mapama247/32/33424_2.png) [@mapama247](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fmapama247)%5C
**Post date:** [April 3, 2023, 8:57am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftypeerror-when-loading-pipeline%2F35023%2F2 "2023-04-03T08:57:57Z")

</div>

> [@AmasDeHousses](#):
>
> from diffusers import DiffusionPipeline  
> pipeline = DiffusionPipeline.from\_pretrained(“runwayml/stable-diffusion-v1-5”)

These two lines work for me using diffusers 0.14.0, which is the latest version released today. Try updating your library (`pip install diffusers==0.14.0`), just in case.

In the [instructions](https://huggingface.co/docs/diffusers/using-diffusers/loading#loading-pipelines-locally) you mention, the only thing I can read about “access request” says:

> […]if you want to use pipelines that require an access request without having to be connected to the Hugging Face Hub, we recommend loading pipelines locally.

Note that you are giving a repository name to the `from_pretrained()` function, which means that it’s downloading the weights from the hub rather than your local filesystem (you should give it a path for that).

---

<div class="post-metadata">

**Author:** ![AmasDeHousses](https://avatars.discourse-cdn.com/v4/letter/a/919ad9/32.png) [@AmasDeHousses](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FAmasDeHousses)%5C
**Post date:** [April 3, 2023, 4:20pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftypeerror-when-loading-pipeline%2F35023%2F3 "2023-04-03T16:20:29Z")

</div>

Thanks, updating diffusers made it work!
