From 52146b8a6b1c0d29e0d18fc6ea8c64579f494b1e Mon Sep 17 00:00:00 2001 From: Julien Simon Date: Tue, 25 Oct 2022 07:39:47 -0700 Subject: [PATCH] Add missing import --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index a5f47dfcb032..ac518fb8ec76 100644 --- a/README.md +++ b/README.md @@ -88,6 +88,7 @@ We recommend using the model in [half-precision (`fp16`)](https://pytorch.org/bl precision while being roughly twice as fast and requiring half the amount of GPU RAM. ```python +import torch from diffusers import StableDiffusionPipeline pipe = StableDiffusionPipeline.from_pretrained("runwayml/stable-diffusion-v1-5", torch_dtype=torch.float16, revision="fp16")