Fucius commited on
Commit
0e3e7cd
1 Parent(s): 2da2632

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -1,3 +1,4 @@
 
1
  import sys
2
  sys.path.append('./')
3
  import gradio as gr
@@ -359,6 +360,7 @@ def main(device, segment_type):
359
  image = Image.fromarray((image * 255.0).clip(0, 255).astype(np.uint8))
360
  return image
361
 
 
362
  def generate_image(prompt1, negative_prompt, man, woman, resolution, local_prompt1, local_prompt2, seed, condition, condition_img1, style):
363
  try:
364
  path1 = lorapath_man[man]
 
1
+ import spaces
2
  import sys
3
  sys.path.append('./')
4
  import gradio as gr
 
360
  image = Image.fromarray((image * 255.0).clip(0, 255).astype(np.uint8))
361
  return image
362
 
363
+ @spaces.GPU
364
  def generate_image(prompt1, negative_prompt, man, woman, resolution, local_prompt1, local_prompt2, seed, condition, condition_img1, style):
365
  try:
366
  path1 = lorapath_man[man]