Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -23,13 +23,13 @@ def generate(image: Image.Image, edit_prompt: str):
|
|
| 23 |
device = device,
|
| 24 |
ip_loaded=False,
|
| 25 |
spatial_condition=True,
|
| 26 |
-
clip_image_processor=
|
| 27 |
image_encoder=None,
|
| 28 |
improj=None,
|
| 29 |
share_position_embedding = True,
|
| 30 |
)
|
| 31 |
|
| 32 |
-
img = image_resize(image,
|
| 33 |
w, h = img.size
|
| 34 |
img = img.resize(((w // 32) * 32, (h // 32) * 32))
|
| 35 |
img = torch.from_numpy((np.array(img) / 127.5) - 1)
|
|
|
|
| 23 |
device = device,
|
| 24 |
ip_loaded=False,
|
| 25 |
spatial_condition=True,
|
| 26 |
+
clip_image_processor=True,
|
| 27 |
image_encoder=None,
|
| 28 |
improj=None,
|
| 29 |
share_position_embedding = True,
|
| 30 |
)
|
| 31 |
|
| 32 |
+
img = image_resize(image, 720)
|
| 33 |
w, h = img.size
|
| 34 |
img = img.resize(((w // 32) * 32, (h // 32) * 32))
|
| 35 |
img = torch.from_numpy((np.array(img) / 127.5) - 1)
|