camparchimedes commited on
Commit
6c09186
1 Parent(s): 1d1c684

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -24,8 +24,6 @@ from transformers import AutoProcessor, pipeline
24
 
25
  MODEL_NAME = "NbAiLabBeta/nb-whisper-large"
26
 
27
- lang = "no"
28
-
29
  device = "cuda" if torch.cuda.is_available() else "cpu"
30
  pipe = pipeline(
31
  task="automatic-speech-recognition",
@@ -35,7 +33,7 @@ pipe = pipeline(
35
  )
36
 
37
 
38
- pipe.model.config.forced_decoder_ids = pipe.tokenizer.get_decoder_prompt_ids(language=lang, task="transcribe")
39
 
40
 
41
 
 
24
 
25
  MODEL_NAME = "NbAiLabBeta/nb-whisper-large"
26
 
 
 
27
  device = "cuda" if torch.cuda.is_available() else "cpu"
28
  pipe = pipeline(
29
  task="automatic-speech-recognition",
 
33
  )
34
 
35
 
36
+ pipe.model.config.forced_decoder_ids = pipe.tokenizer.get_decoder_prompt_ids(language="no", task="transcribe")
37
 
38
 
39