Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -56,9 +56,13 @@ if image is not None:
|
|
56 |
|
57 |
with st.spinner("🤖 AI is at Work! "):
|
58 |
|
59 |
-
|
60 |
-
|
|
|
|
|
|
|
61 |
images = pipe(prompt, image=image, num_inference_steps=10, image_guidance_scale=1).images
|
|
|
62 |
images[0].show()
|
63 |
|
64 |
|
|
|
56 |
|
57 |
with st.spinner("🤖 AI is at Work! "):
|
58 |
|
59 |
+
model_id = "timbrooks/instruct-pix2pix"
|
60 |
+
pipe = StableDiffusionInstructPix2PixPipeline.from_pretrained(model_id, torch_dtype=torch.float16, safety_checker=None)
|
61 |
+
pipe.to("cuda")
|
62 |
+
pipe.scheduler = EulerAncestralDiscreteScheduler.from_config(pipe.scheduler.config)
|
63 |
+
|
64 |
images = pipe(prompt, image=image, num_inference_steps=10, image_guidance_scale=1).images
|
65 |
+
|
66 |
images[0].show()
|
67 |
|
68 |
|