File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -230,12 +230,12 @@ def __init__(
230230 """Initialize the CTCSegmentation module."""
231231 # Prepare ASR model
232232 if not (
233- hasattr (asr_model , "modules " )
234- and hasattr (asr_model .modules , "decoder" )
235- and hasattr (asr_model .modules .decoder , "ctc_weight" )
233+ hasattr (asr_model , "mods " )
234+ and hasattr (asr_model .mods , "decoder" )
235+ and hasattr (asr_model .mods .decoder , "ctc_weight" )
236236 ):
237237 raise AttributeError (
238- "The given asr_model has no CTC decoder in asr_model.modules .decoder!"
238+ "The given asr_model has no CTC decoder in asr_model.mods .decoder!"
239239 )
240240 if not hasattr (asr_model , "tokenizer" ):
241241 raise AttributeError (
@@ -244,7 +244,7 @@ def __init__(
244244 self .asr_model = asr_model
245245 self ._encode = self .asr_model .encode_batch
246246 # Assumption: log-softmax is already included in ctc_forward_step
247- self ._ctc = self .asr_model .modules .decoder .ctc_forward_step
247+ self ._ctc = self .asr_model .mods .decoder .ctc_forward_step
248248 self ._tokenizer = self .asr_model .tokenizer
249249
250250 # Apply configuration
You can’t perform that action at this time.
0 commit comments