Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -140,7 +140,6 @@ def set_seed(seed):
|
|
| 140 |
return seed
|
| 141 |
|
| 142 |
# Text to Image function with thinking option and hyperparameters
|
| 143 |
-
@spaces.GPU(duration=90)
|
| 144 |
def text_to_image(prompt, show_thinking=False, cfg_text_scale=4.0, cfg_interval=0.4,
|
| 145 |
timestep_shift=3.0, num_timesteps=50,
|
| 146 |
cfg_renorm_min=1.0, cfg_renorm_type="global",
|
|
@@ -187,7 +186,6 @@ def text_to_image(prompt, show_thinking=False, cfg_text_scale=4.0, cfg_interval=
|
|
| 187 |
|
| 188 |
|
| 189 |
# Image Understanding function with thinking option and hyperparameters
|
| 190 |
-
@spaces.GPU(duration=90)
|
| 191 |
def image_understanding(image: Image.Image, prompt: str, show_thinking=False,
|
| 192 |
do_sample=False, text_temperature=0.3, max_new_tokens=512):
|
| 193 |
if image is None:
|
|
@@ -217,7 +215,6 @@ def image_understanding(image: Image.Image, prompt: str, show_thinking=False,
|
|
| 217 |
|
| 218 |
|
| 219 |
# Image Editing function with thinking option and hyperparameters
|
| 220 |
-
@spaces.GPU(duration=90)
|
| 221 |
def edit_image(image: Image.Image, prompt: str, show_thinking=False, cfg_text_scale=4.0,
|
| 222 |
cfg_img_scale=2.0, cfg_interval=0.0,
|
| 223 |
timestep_shift=3.0, num_timesteps=50, cfg_renorm_min=1.0,
|
|
|
|
| 140 |
return seed
|
| 141 |
|
| 142 |
# Text to Image function with thinking option and hyperparameters
|
|
|
|
| 143 |
def text_to_image(prompt, show_thinking=False, cfg_text_scale=4.0, cfg_interval=0.4,
|
| 144 |
timestep_shift=3.0, num_timesteps=50,
|
| 145 |
cfg_renorm_min=1.0, cfg_renorm_type="global",
|
|
|
|
| 186 |
|
| 187 |
|
| 188 |
# Image Understanding function with thinking option and hyperparameters
|
|
|
|
| 189 |
def image_understanding(image: Image.Image, prompt: str, show_thinking=False,
|
| 190 |
do_sample=False, text_temperature=0.3, max_new_tokens=512):
|
| 191 |
if image is None:
|
|
|
|
| 215 |
|
| 216 |
|
| 217 |
# Image Editing function with thinking option and hyperparameters
|
|
|
|
| 218 |
def edit_image(image: Image.Image, prompt: str, show_thinking=False, cfg_text_scale=4.0,
|
| 219 |
cfg_img_scale=2.0, cfg_interval=0.0,
|
| 220 |
timestep_shift=3.0, num_timesteps=50, cfg_renorm_min=1.0,
|