Spaces:
Runtime error
Runtime error
LanHarmony
commited on
Commit
•
5147e50
1
Parent(s):
3ef2358
add infinity and chinese support
Browse files
visual_foundation_models.py
CHANGED
@@ -843,7 +843,7 @@ class InfinityOutPainting:
|
|
843 |
f'Prompt: {caption}')
|
844 |
return caption
|
845 |
|
846 |
-
def resize_image(self, image, max_size=
|
847 |
aspect_ratio = image.size[0] / image.size[1]
|
848 |
new_width = int(math.sqrt(max_size * aspect_ratio))
|
849 |
new_height = int(new_width / aspect_ratio)
|
|
|
843 |
f'Prompt: {caption}')
|
844 |
return caption
|
845 |
|
846 |
+
def resize_image(self, image, max_size=100000, multiple=8):
|
847 |
aspect_ratio = image.size[0] / image.size[1]
|
848 |
new_width = int(math.sqrt(max_size * aspect_ratio))
|
849 |
new_height = int(new_width / aspect_ratio)
|