Training in progress, step 2000
Browse files
.ipynb_checkpoints/run_speech_recognition_seq2seq_streaming-checkpoint.py
CHANGED
@@ -503,7 +503,8 @@ def main():
|
|
503 |
)
|
504 |
|
505 |
# 8. Load Metric
|
506 |
-
|
|
|
507 |
do_normalize_eval = data_args.do_normalize_eval
|
508 |
|
509 |
def compute_metrics(pred):
|
@@ -519,9 +520,9 @@ def main():
|
|
519 |
pred_str = [normalizer(pred) for pred in pred_str]
|
520 |
label_str = [normalizer(label) for label in label_str]
|
521 |
|
522 |
-
wer = 100 *
|
523 |
-
|
524 |
-
return {"wer": wer}
|
525 |
|
526 |
# 9. Create a single speech processor
|
527 |
if is_main_process(training_args.local_rank):
|
|
|
503 |
)
|
504 |
|
505 |
# 8. Load Metric
|
506 |
+
wer_metric = evaluate.load("wer")
|
507 |
+
cer_metric = evaluate.load("cer")
|
508 |
do_normalize_eval = data_args.do_normalize_eval
|
509 |
|
510 |
def compute_metrics(pred):
|
|
|
520 |
pred_str = [normalizer(pred) for pred in pred_str]
|
521 |
label_str = [normalizer(label) for label in label_str]
|
522 |
|
523 |
+
wer = 100 * wer_metric.compute(predictions=pred_str, references=label_str)
|
524 |
+
cer = 100 * cer_metric.compute(predictions=pred_str, references=label_str)
|
525 |
+
return {"wer": wer, "cer": cer}
|
526 |
|
527 |
# 9. Create a single speech processor
|
528 |
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:
|
3 |
size 3055754841
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:37b5095f4fe9fd5d21d56860798771af0eb99bbb25d343e7f2bafc654d68aa54
|
3 |
size 3055754841
|
run_speech_recognition_seq2seq_streaming.py
CHANGED
@@ -503,7 +503,8 @@ def main():
|
|
503 |
)
|
504 |
|
505 |
# 8. Load Metric
|
506 |
-
|
|
|
507 |
do_normalize_eval = data_args.do_normalize_eval
|
508 |
|
509 |
def compute_metrics(pred):
|
@@ -519,9 +520,9 @@ def main():
|
|
519 |
pred_str = [normalizer(pred) for pred in pred_str]
|
520 |
label_str = [normalizer(label) for label in label_str]
|
521 |
|
522 |
-
wer = 100 *
|
523 |
-
|
524 |
-
return {"wer": wer}
|
525 |
|
526 |
# 9. Create a single speech processor
|
527 |
if is_main_process(training_args.local_rank):
|
|
|
503 |
)
|
504 |
|
505 |
# 8. Load Metric
|
506 |
+
wer_metric = evaluate.load("wer")
|
507 |
+
cer_metric = evaluate.load("cer")
|
508 |
do_normalize_eval = data_args.do_normalize_eval
|
509 |
|
510 |
def compute_metrics(pred):
|
|
|
520 |
pred_str = [normalizer(pred) for pred in pred_str]
|
521 |
label_str = [normalizer(label) for label in label_str]
|
522 |
|
523 |
+
wer = 100 * wer_metric.compute(predictions=pred_str, references=label_str)
|
524 |
+
cer = 100 * cer_metric.compute(predictions=pred_str, references=label_str)
|
525 |
+
return {"wer": wer, "cer": cer}
|
526 |
|
527 |
# 9. Create a single speech processor
|
528 |
if is_main_process(training_args.local_rank):
|
runs/Dec07_07-28-49_140-238-225-207/events.out.tfevents.1670398176.140-238-225-207.101704.0
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:4604f98bfd0b98cf07086f9f4eda9a14274d55c504429b30c27eb702622d8ed1
|
3 |
+
size 17387
|