geninhu commited on
Commit
15fb666
1 Parent(s): a7ad2ae

Training in progress, step 4000

Browse files
.ipynb_checkpoints/run_speech_recognition_seq2seq_streaming-checkpoint.py CHANGED
@@ -511,7 +511,8 @@ def main():
511
  )
512
 
513
  # 8. Load Metric
514
- metric = evaluate.load("wer")
 
515
  do_normalize_eval = data_args.do_normalize_eval
516
 
517
  def compute_metrics(pred):
@@ -527,9 +528,10 @@ def main():
527
  pred_str = [normalizer(pred) for pred in pred_str]
528
  label_str = [normalizer(label) for label in label_str]
529
 
530
- wer = 100 * metric.compute(predictions=pred_str, references=label_str)
 
531
 
532
- return {"wer": wer}
533
 
534
  # 9. Create a single speech processor
535
  if is_main_process(training_args.local_rank):
 
511
  )
512
 
513
  # 8. Load Metric
514
+ wer_metric = evaluate.load("wer")
515
+ cer_metric = evaluate.load("cer")
516
  do_normalize_eval = data_args.do_normalize_eval
517
 
518
  def compute_metrics(pred):
 
528
  pred_str = [normalizer(pred) for pred in pred_str]
529
  label_str = [normalizer(label) for label in label_str]
530
 
531
+ wer = 100 * wer_metric.compute(predictions=pred_str, references=label_str)
532
+ cer = 100 * cer_metric.compute(predictions=pred_str, references=label_str)
533
 
534
+ return {"wer": wer, "cer": cer}
535
 
536
  # 9. Create a single speech processor
537
  if is_main_process(training_args.local_rank):
pytorch_model.bin CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:15cc998a71fc9f07d4acfb885b983dac7b6ece2d8c0d1dedd6374dd6c8d8ddcf
3
  size 3055754841
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:74502c29f79feacae7fad9595f99a0a6e3b581b72e0b2c9490ba8016f6deaab6
3
  size 3055754841
run_speech_recognition_seq2seq_streaming.py CHANGED
@@ -511,7 +511,8 @@ def main():
511
  )
512
 
513
  # 8. Load Metric
514
- metric = evaluate.load("wer")
 
515
  do_normalize_eval = data_args.do_normalize_eval
516
 
517
  def compute_metrics(pred):
@@ -527,9 +528,10 @@ def main():
527
  pred_str = [normalizer(pred) for pred in pred_str]
528
  label_str = [normalizer(label) for label in label_str]
529
 
530
- wer = 100 * metric.compute(predictions=pred_str, references=label_str)
 
531
 
532
- return {"wer": wer}
533
 
534
  # 9. Create a single speech processor
535
  if is_main_process(training_args.local_rank):
 
511
  )
512
 
513
  # 8. Load Metric
514
+ wer_metric = evaluate.load("wer")
515
+ cer_metric = evaluate.load("cer")
516
  do_normalize_eval = data_args.do_normalize_eval
517
 
518
  def compute_metrics(pred):
 
528
  pred_str = [normalizer(pred) for pred in pred_str]
529
  label_str = [normalizer(label) for label in label_str]
530
 
531
+ wer = 100 * wer_metric.compute(predictions=pred_str, references=label_str)
532
+ cer = 100 * cer_metric.compute(predictions=pred_str, references=label_str)
533
 
534
+ return {"wer": wer, "cer": cer}
535
 
536
  # 9. Create a single speech processor
537
  if is_main_process(training_args.local_rank):
runs/Dec08_05-32-25_132-145-179-103/events.out.tfevents.1670477595.132-145-179-103.68786.0 CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:bb7512059fcb49baa3398782de0052ee9975c204d8d6814444b3fdbb67228e85
3
- size 23985
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d3086d33316684db3a8233211dd593825bb283af845f99ed1361599b98b4c0dd
3
+ size 30583