Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -38,7 +38,8 @@ def genie (input_image, prompt, negative_prompt, width, height, steps, seed, con
|
|
38 |
image = np.concatenate([image, image, image], axis=2)
|
39 |
#cv2.imwrite('canny.png', image)
|
40 |
image = Image.fromarray(image)
|
41 |
-
|
|
|
42 |
#generating a new image
|
43 |
generator = np.random.seed(0) if seed == 0 else torch.manual_seed(seed)
|
44 |
int_image = pipe(prompt=prompt, negative_prompt=negative_prompt, width=width, height=height, generator=generator, num_inference_steps=steps, guidance_scale=4, image=image, controlnet_conditioning_scale=conditioning_scale).images[0]
|
|
|
38 |
image = np.concatenate([image, image, image], axis=2)
|
39 |
#cv2.imwrite('canny.png', image)
|
40 |
image = Image.fromarray(image)
|
41 |
+
|
42 |
+
conditioning_scale = float(conditioning_scale)
|
43 |
#generating a new image
|
44 |
generator = np.random.seed(0) if seed == 0 else torch.manual_seed(seed)
|
45 |
int_image = pipe(prompt=prompt, negative_prompt=negative_prompt, width=width, height=height, generator=generator, num_inference_steps=steps, guidance_scale=4, image=image, controlnet_conditioning_scale=conditioning_scale).images[0]
|