Skip to content

Commit 77465a3

Browse files
github-actions[bot]nithinraok
authored andcommitted
add ensemble decoding fix (#8427) (#8433)
Signed-off-by: Nithin Rao Koluguri <nithinraok> Co-authored-by: Nithin Rao <[email protected]> Signed-off-by: Pablo Garay <[email protected]>
1 parent 81b898c commit 77465a3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/asr/transcribe_speech.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ def main(cfg: TranscriptionConfig) -> Union[TranscriptionConfig, List[Hypothesis
265265
asr_model.encoder.set_default_att_context_size(cfg.att_context_size)
266266

267267
# Setup decoding strategy
268-
if hasattr(asr_model, 'change_decoding_strategy'):
268+
if hasattr(asr_model, 'change_decoding_strategy') and hasattr(asr_model, 'decoding'):
269269
if isinstance(asr_model.decoding, MultiTaskDecoding):
270270
cfg.multitask_decoding.compute_langs = cfg.compute_langs
271271
cfg.multitask_decoding.preserve_alignments = cfg.preserve_alignment

0 commit comments

Comments
 (0)