thomas0104 commited on
Commit
27319f3
·
1 Parent(s): 8d5b1e9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -1,5 +1,3 @@
1
- import torch
2
-
3
  import gradio as gr
4
  import pytube as pt
5
  from transformers import pipeline
@@ -8,7 +6,7 @@ from huggingface_hub import model_info
8
  MODEL_NAME = "thomas0104/whisper-large-v2-nan-tw-only-char" #this always needs to stay in line 8 :D sorry for the hackiness
9
  lang = "chinese"
10
 
11
- device = 0 if torch.cuda.is_available() else "cpu"
12
  pipe = pipeline(
13
  task="automatic-speech-recognition",
14
  model=MODEL_NAME,
 
 
 
1
  import gradio as gr
2
  import pytube as pt
3
  from transformers import pipeline
 
6
  MODEL_NAME = "thomas0104/whisper-large-v2-nan-tw-only-char" #this always needs to stay in line 8 :D sorry for the hackiness
7
  lang = "chinese"
8
 
9
+
10
  pipe = pipeline(
11
  task="automatic-speech-recognition",
12
  model=MODEL_NAME,