bofenghuang commited on
Commit
88c0c58
·
1 Parent(s): 48e5445
Files changed (1) hide show
  1. run_demo_multi_models.py +3 -1
run_demo_multi_models.py CHANGED
@@ -18,6 +18,7 @@ MODEL_NAMES = [
18
  "bofenghuang/whisper-large-v2-cv11-french",
19
  ]
20
  CHUNK_LENGTH_S = 30
 
21
  # MAX_NEW_TOKENS = 225
22
 
23
  logging.basicConfig(
@@ -54,7 +55,8 @@ def maybe_load_cached_pipeline(model_name):
54
  pipe = pipeline(
55
  task="automatic-speech-recognition",
56
  model=model_name,
57
- # chunk_length_s=CHUNK_LENGTH_S,
 
58
  device=device,
59
  )
60
  # set forced_decoder_ids
 
18
  "bofenghuang/whisper-large-v2-cv11-french",
19
  ]
20
  CHUNK_LENGTH_S = 30
21
+ STRIDE_LENGTH_S = 0
22
  # MAX_NEW_TOKENS = 225
23
 
24
  logging.basicConfig(
 
55
  pipe = pipeline(
56
  task="automatic-speech-recognition",
57
  model=model_name,
58
+ chunk_length_s=CHUNK_LENGTH_S,
59
+ stride_length_s=STRIDE_LENGTH_S,
60
  device=device,
61
  )
62
  # set forced_decoder_ids