Spaces:
Running
on
Zero
Running
on
Zero
Upload folder using huggingface_hub
Browse files
app.py
CHANGED
@@ -62,9 +62,6 @@ def generate_images(
|
|
62 |
if img2img_enabled and img2img_image is not None:
|
63 |
# Convert numpy array to PIL Image
|
64 |
if isinstance(img2img_image, np.ndarray):
|
65 |
-
# Convert BGR to RGB if needed
|
66 |
-
if img2img_image.shape[-1] == 3:
|
67 |
-
img2img_image = cv2.cvtColor(img2img_image, cv2.COLOR_BGR2RGB)
|
68 |
img_pil = Image.fromarray(img2img_image)
|
69 |
img_pil.save("temp_img2img.png")
|
70 |
prompt = "temp_img2img.png"
|
|
|
62 |
if img2img_enabled and img2img_image is not None:
|
63 |
# Convert numpy array to PIL Image
|
64 |
if isinstance(img2img_image, np.ndarray):
|
|
|
|
|
|
|
65 |
img_pil = Image.fromarray(img2img_image)
|
66 |
img_pil.save("temp_img2img.png")
|
67 |
prompt = "temp_img2img.png"
|