diff --git a/.flake8 b/.flake8 index b8f0e4715..19c3a9bd6 100644 --- a/.flake8 +++ b/.flake8 @@ -5,6 +5,7 @@ max-line-length = 80 per-file-ignores = # line too long egs/librispeech/ASR/*/conformer.py: E501, + egs/aishell/ASR/*/conformer.py: E501, exclude = .git, diff --git a/egs/aishell/ASR/local/compute_fbank_aishell.py b/egs/aishell/ASR/local/compute_fbank_aishell.py index d170931db..df696dbf5 100755 --- a/egs/aishell/ASR/local/compute_fbank_aishell.py +++ b/egs/aishell/ASR/local/compute_fbank_aishell.py @@ -107,4 +107,3 @@ if __name__ == "__main__": args = get_args() compute_fbank_aishell(num_mel_bins=args.num_mel_bins) - diff --git a/egs/aishell/ASR/local/compute_fbank_musan.py b/egs/aishell/ASR/local/compute_fbank_musan.py index 4b0120283..0a5d82ccb 100755 --- a/egs/aishell/ASR/local/compute_fbank_musan.py +++ b/egs/aishell/ASR/local/compute_fbank_musan.py @@ -87,6 +87,7 @@ def compute_fbank_musan(num_mel_bins: int = 80): ) musan_cuts.to_json(musan_cuts_path) + def get_args(): parser = argparse.ArgumentParser() parser.add_argument( diff --git a/egs/aishell/ASR/local/prepare_char.py b/egs/aishell/ASR/local/prepare_char.py index 5b4ec323d..421b1c3d6 100755 --- a/egs/aishell/ASR/local/prepare_char.py +++ b/egs/aishell/ASR/local/prepare_char.py @@ -33,10 +33,9 @@ and generates the following files in the directory `lang_dir`: - tokens.txt """ -import argparse import re from pathlib import Path -from typing import Dict, List, Tuple +from typing import Dict, List import k2 import torch diff --git a/icefall/decode.py b/icefall/decode.py index 8bf4460d4..4c2a8e01b 100644 --- a/icefall/decode.py +++ b/icefall/decode.py @@ -903,4 +903,3 @@ def rescore_with_attention_decoder( key = f"ngram_lm_scale_{n_scale}_attention_scale_{a_scale}" ans[key] = best_path return ans -