From dfb66c4475183ab9dcef40b6e0da367e91130e65 Mon Sep 17 00:00:00 2001 From: Edward Li Date: Sat, 9 Dec 2023 01:02:10 -0500 Subject: [PATCH] Correct type annotation for `VaeImageProcessor.numpy_to_pil` From `(np.ndarray) -> PIL.Image.Image` to `(np.ndarray) -> List[PIL.Image.Image]`. --- src/diffusers/image_processor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/diffusers/image_processor.py b/src/diffusers/image_processor.py index a515805fd087..ab96384fe9f1 100644 --- a/src/diffusers/image_processor.py +++ b/src/diffusers/image_processor.py @@ -88,7 +88,7 @@ def __init__( self.config.do_convert_rgb = False @staticmethod - def numpy_to_pil(images: np.ndarray) -> PIL.Image.Image: + def numpy_to_pil(images: np.ndarray) -> List[PIL.Image.Image]: """ Convert a numpy image or a batch of images to a PIL image. """