Commit
•
c11e306
1
Parent(s):
3451c21
Update app.py
Browse files
app.py
CHANGED
@@ -29,18 +29,18 @@ pipe.enable_xformers_memory_efficient_attention()
|
|
29 |
def super_esr(source_image,prompt,negative_prompt,strength,seed,num_inference_steps):
|
30 |
condition_image = resize_for_condition_image(source_image, 1024)
|
31 |
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
# print(source_image,prompt,negative_prompt,strength,seed,num_inference_steps)
|
43 |
-
return
|
44 |
|
45 |
#define laund take input nsame as super_esr function
|
46 |
|
|
|
29 |
def super_esr(source_image,prompt,negative_prompt,strength,seed,num_inference_steps):
|
30 |
condition_image = resize_for_condition_image(source_image, 1024)
|
31 |
|
32 |
+
image = pipe(prompt=prompt,#"best quality",
|
33 |
+
negative_prompt="blur, lowres, bad anatomy, bad hands, cropped, worst quality",
|
34 |
+
image=condition_image,
|
35 |
+
controlnet_conditioning_image=condition_image,
|
36 |
+
width=condition_image.size[0],
|
37 |
+
height=condition_image.size[1],
|
38 |
+
strength=1.0,
|
39 |
+
generator=seed,
|
40 |
+
num_inference_steps=num_inference_steps,
|
41 |
+
).image
|
42 |
# print(source_image,prompt,negative_prompt,strength,seed,num_inference_steps)
|
43 |
+
return image
|
44 |
|
45 |
#define laund take input nsame as super_esr function
|
46 |
|