diff --git a/egs/tedlium2/ASR/conformer_ctc2/.decode.py.swp b/egs/tedlium2/ASR/conformer_ctc2/.decode.py.swp index 0f873fe80..b04292c6d 100644 Binary files a/egs/tedlium2/ASR/conformer_ctc2/.decode.py.swp and b/egs/tedlium2/ASR/conformer_ctc2/.decode.py.swp differ diff --git a/egs/tedlium2/ASR/conformer_ctc2/decode.py b/egs/tedlium2/ASR/conformer_ctc2/decode.py index b99c48cfe..65f99d9c9 100755 --- a/egs/tedlium2/ASR/conformer_ctc2/decode.py +++ b/egs/tedlium2/ASR/conformer_ctc2/decode.py @@ -28,7 +28,7 @@ import k2 import sentencepiece as spm import torch import torch.nn as nn -from asr_datamodule import LibriSpeechAsrDataModule +from asr_datamodule import TedAsrDataModule from conformer import Conformer from icefall.bpe_graph_compiler import BpeCtcTrainingGraphCompiler @@ -731,7 +731,7 @@ def save_results( @torch.no_grad() def main(): parser = get_parser() - LibriSpeechAsrDataModule.add_arguments(parser) + TedAsrDataModule.add_arguments(parser) args = parser.parse_args() args.exp_dir = Path(args.exp_dir) args.lang_dir = Path(args.lang_dir) @@ -960,13 +960,22 @@ def main(): # we need cut ids to display recognition results. args.return_cuts = True - librispeech = LibriSpeechAsrDataModule(args) + tedlium = TedAsrDataModule(args) - test_clean_cuts = librispeech.test_clean_cuts() - test_other_cuts = librispeech.test_other_cuts() + #test_clean_cuts = librispeech.test_clean_cuts() + #test_other_cuts = librispeech.test_other_cuts() - test_clean_dl = librispeech.test_dataloaders(test_clean_cuts) - test_other_dl = librispeech.test_dataloaders(test_other_cuts) + #test_clean_dl = librispeech.test_dataloaders(test_clean_cuts) + #test_other_dl = librispeech.test_dataloaders(test_other_cuts) + + #test_sets = ["test-clean", "test-other"] + #test_dl = [test_clean_dl, test_other_dl] + + dev_cuts = tedlium.dev_cuts() + test_cuts = tedlium.test_cuts() + + dev_dl = tedlium.valid_dataloaders(test_clean_cuts) + test_dl = tedlium.test_dataloaders(test_other_cuts) test_sets = ["test-clean", "test-other"] test_dl = [test_clean_dl, test_other_dl]