Commit bf2c4a4 1 parent f3ad327 commit bf2c4a4 Copy full SHA for bf2c4a4
File tree 2 files changed +0
-20
lines changed
pruned_transducer_stateless
2 files changed +0
-20
lines changed Original file line number Diff line number Diff line change @@ -658,18 +658,8 @@ def remove_short_and_long_utt(c: Cut):
658
658
# Keep only utterances with duration between 1 second and 17 seconds
659
659
return 1.0 <= c .duration <= 17.0
660
660
661
- num_in_total = len (train_cuts )
662
-
663
661
train_cuts = train_cuts .filter (remove_short_and_long_utt )
664
662
665
- num_left = len (train_cuts )
666
- num_removed = num_in_total - num_left
667
- removed_percent = num_removed / num_in_total * 100
668
-
669
- logging .info (f"Before removing short and long utterances: { num_in_total } " )
670
- logging .info (f"After removing short and long utterances: { num_left } " )
671
- logging .info (f"Removed { num_removed } utterances ({ removed_percent :.5f} %)" )
672
-
673
663
train_dl = tedlium .train_dataloaders (train_cuts )
674
664
valid_cuts = tedlium .dev_cuts ()
675
665
valid_dl = tedlium .valid_dataloaders (valid_cuts )
Original file line number Diff line number Diff line change @@ -627,18 +627,8 @@ def remove_short_and_long_utt(c: Cut):
627
627
# Keep only utterances with duration between 1 second and 17 seconds
628
628
return 1.0 <= c .duration <= 17.0
629
629
630
- num_in_total = len (train_cuts )
631
-
632
630
train_cuts = train_cuts .filter (remove_short_and_long_utt )
633
631
634
- num_left = len (train_cuts )
635
- num_removed = num_in_total - num_left
636
- removed_percent = num_removed / num_in_total * 100
637
-
638
- logging .info (f"Before removing short and long utterances: { num_in_total } " )
639
- logging .info (f"After removing short and long utterances: { num_left } " )
640
- logging .info (f"Removed { num_removed } utterances ({ removed_percent :.5f} %)" )
641
-
642
632
train_dl = tedlium .train_dataloaders (train_cuts )
643
633
valid_cuts = tedlium .dev_cuts ()
644
634
valid_dl = tedlium .valid_dataloaders (valid_cuts )
You can’t perform that action at this time.
0 commit comments