Skip to content

Commit

Permalink
minor fixes (#1332)
Browse files Browse the repository at this point in the history
  • Loading branch information
JinZr authored Oct 24, 2023
1 parent 92ef561 commit f9980aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions egs/libriheavy/ASR/zipformer_prompt_asr/decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ def __init__(
# To avoid `RuntimeError: Module 'Decoder' has no attribute 'conv'`
# when inference with torch.jit.script and context_size == 1
self.conv = nn.Identity()
self.balancer2 = nn.Identity()

def forward(self, y: torch.Tensor, need_pad: bool = True) -> torch.Tensor:
"""
Expand Down
1 change: 1 addition & 0 deletions egs/librispeech/ASR/zipformer/decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ def __init__(
# To avoid `RuntimeError: Module 'Decoder' has no attribute 'conv'`
# when inference with torch.jit.script and context_size == 1
self.conv = nn.Identity()
self.balancer2 = nn.Identity()

def forward(self, y: torch.Tensor, need_pad: bool = True) -> torch.Tensor:
"""
Expand Down

0 comments on commit f9980aa

Please sign in to comment.