JiantaoLin
commited on
Commit
Β·
24165b8
1
Parent(s):
138cabe
new
Browse files
app.py
CHANGED
@@ -149,8 +149,8 @@ def text_to_detailed(prompt, seed=None):
|
|
149 |
# print(f"Before text_to_detailed: {torch.cuda.memory_allocated() / 1024**3} GB")
|
150 |
return k3d_wrapper.get_detailed_prompt(prompt, seed)
|
151 |
|
152 |
-
@spaces.GPU
|
153 |
-
def text_to_image(prompt, seed=None, strength=1.0,lora_scale=1.0, num_inference_steps=
|
154 |
# print(f"Before text_to_image: {torch.cuda.memory_allocated() / 1024**3} GB")
|
155 |
k3d_wrapper.renew_uuid()
|
156 |
init_image = None
|
|
|
149 |
# print(f"Before text_to_detailed: {torch.cuda.memory_allocated() / 1024**3} GB")
|
150 |
return k3d_wrapper.get_detailed_prompt(prompt, seed)
|
151 |
|
152 |
+
@spaces.GPU(duration=120)
|
153 |
+
def text_to_image(prompt, seed=None, strength=1.0,lora_scale=1.0, num_inference_steps=20, redux_hparam=None, init_image=None, **kwargs):
|
154 |
# print(f"Before text_to_image: {torch.cuda.memory_allocated() / 1024**3} GB")
|
155 |
k3d_wrapper.renew_uuid()
|
156 |
init_image = None
|