AbstractPhil commited on
Commit
12aa86c
Β·
1 Parent(s): c34205b
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -1,3 +1,4 @@
 
1
  import torch
2
  import gradio as gr
3
  import numpy as np
@@ -134,6 +135,7 @@ def encode_sdxl_prompt(prompt, negative_prompt=""):
134
  }
135
 
136
  # ─── Inference ────────────────────────────────────────────────
 
137
  @torch.no_grad()
138
  def infer(prompt, negative_prompt, adapter_l_file, adapter_g_file, strength, noise, gate_prob,
139
  use_anchor, steps, cfg_scale, scheduler_name, width, height, seed):
 
1
+ import spaces
2
  import torch
3
  import gradio as gr
4
  import numpy as np
 
135
  }
136
 
137
  # ─── Inference ────────────────────────────────────────────────
138
+ @spaces.GPU
139
  @torch.no_grad()
140
  def infer(prompt, negative_prompt, adapter_l_file, adapter_g_file, strength, noise, gate_prob,
141
  use_anchor, steps, cfg_scale, scheduler_name, width, height, seed):