hungchiayu1 commited on
Commit
a258601
1 Parent(s): 88895ae

fixed bugs

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -68,10 +68,9 @@ class Tango:
68
  return list(self.chunks(outputs, samples))
69
 
70
  # Initialize TANGO
71
- if torch.cuda.is_available():
72
- tango = Tango(device="cuda")
73
- else:
74
- tango = Tango(device="cpu")
75
 
76
  @spaces.GPU(duration=240)
77
  def gradio_generate(prompt, steps, guidance):
 
68
  return list(self.chunks(outputs, samples))
69
 
70
  # Initialize TANGO
71
+
72
+ tango = Tango(device="cpu")
73
+ tango.to("cuda")
 
74
 
75
  @spaces.GPU(duration=240)
76
  def gradio_generate(prompt, steps, guidance):