# How to load stable diffusion ckpt file in diffusers library?

**URL:** <https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851>\
**Category:** 🧨 Diffusers\
**Created:** [October 23, 2022, 6:19pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851 "2022-10-23T18:19:03Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![sausax](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/sausax/32/12200_2.png) [@sausax](https://discuss.huggingface.co/u/sausax)\
**Post date:** [October 23, 2022, 6:19pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851/1 "2022-10-23T18:19:03Z")

</div>

Hi, Is there a example somewhere on how to load a stable diffusion ckpt file present on local system using diffuser library ?

I want to load some custom trained dreambooth models.

---

<div class="post-metadata">

**Author:** ![sausax](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/sausax/32/12200_2.png) [@sausax](https://discuss.huggingface.co/u/sausax)\
**Post date:** [October 23, 2022, 11:43pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851/2 "2022-10-23T23:43:41Z")

</div>

nvm found it [diffusers/convert\_original\_stable\_diffusion\_to\_diffusers.py at main · huggingface/diffusers · GitHub](https://github.com/huggingface/diffusers/blob/main/scripts/convert_original_stable_diffusion_to_diffusers.py)

---

<div class="post-metadata">

**Author:** ![flyyufelix](https://avatars.discourse-cdn.com/v4/letter/f/b2d939/32.png) [@flyyufelix](https://discuss.huggingface.co/u/flyyufelix)\
**Post date:** [November 5, 2022, 3:41pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851/3 "2022-11-05T15:41:56Z")

</div>

I also want to load stable diffusion ckpt file to diffusers library. Can you show us exactly how you did that? Appreciated!

---

<div class="post-metadata">

**Author:** ![sausax](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/sausax/32/12200_2.png) [@sausax](https://discuss.huggingface.co/u/sausax)\
**Post date:** [November 5, 2022, 8:17pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851/4 "2022-11-05T20:17:47Z")

</div>

Just run the script linked above. It takes in the input file and output directory.

---

<div class="post-metadata">

**Author:** ![syedaliusman](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@syedaliusman](https://discuss.huggingface.co/u/syedaliusman)\
**Post date:** [June 12, 2023, 8:09pm UTC](https://discuss.huggingface.co/t/how-to-load-stable-diffusion-ckpt-file-in-diffusers-library/24851/5 "2023-06-12T20:09:34Z")

</div>

where to run this script
