1
0
mirror of https://github.com/huggingface/diffusers.git synced 2026-01-29 07:22:12 +03:00

Fixed incorrect width/height assignment in StableDiffusionDepth2ImgPi… (#2558)

Fixed incorrect width/height assignment in StableDiffusionDepth2ImgPipeline when passing in tensor
This commit is contained in:
Antoine Bouthors
2023-03-09 22:55:36 +13:00
committed by GitHub
parent 186689affd
commit 75f1210a0c

View File

@@ -447,7 +447,7 @@ class StableDiffusionDepth2ImgPipeline(DiffusionPipeline):
if isinstance(image[0], PIL.Image.Image):
width, height = image[0].size
else:
width, height = image[0].shape[-2:]
height, width = image[0].shape[-2:]
if depth_map is None:
pixel_values = self.feature_extractor(images=image, return_tensors="pt").pixel_values