Skip to content

Commit c14c141

Browse files
TensorRT Inpaint pipeline: minor fixes (#4457)
Signed-off-by: Asfiya Baig <asfiyab@nvidia.com>
1 parent 79ef9e5 commit c14c141

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

examples/community/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1646,13 +1646,13 @@ from io import BytesIO
16461646
from PIL import Image
16471647
import torch
16481648
from diffusers import PNDMScheduler
1649-
from diffusers.pipelines.stable_diffusion import StableDiffusionImg2ImgPipeline
1649+
from diffusers.pipelines.stable_diffusion import StableDiffusionInpaintPipeline
16501650

16511651
# Use the PNDMScheduler scheduler here instead
16521652
scheduler = PNDMScheduler.from_pretrained("stabilityai/stable-diffusion-2-inpainting", subfolder="scheduler")
16531653

16541654

1655-
pipe = StableDiffusionImg2ImgPipeline.from_pretrained("stabilityai/stable-diffusion-2-inpainting",
1655+
pipe = StableDiffusionInpaintPipeline.from_pretrained("stabilityai/stable-diffusion-2-inpainting",
16561656
custom_pipeline="stable_diffusion_tensorrt_inpaint",
16571657
revision='fp16',
16581658
torch_dtype=torch.float16,

examples/community/stable_diffusion_tensorrt_inpaint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1054,7 +1054,7 @@ def __call__(
10541054
return_image=True,
10551055
),
10561056
)
1057-
# print(mask)
1057+
10581058
mask = torch.nn.functional.interpolate(mask, size=(latent_height, latent_width))
10591059
mask = torch.cat([mask] * 2)
10601060

0 commit comments

Comments
 (0)