mirror of
https://github.com/k2-fsa/icefall.git
synced 2025-09-03 22:24:19 +00:00
Fix finalize error in contextgraph
This commit is contained in:
parent
140e6381ad
commit
e06e128d73
@ -240,8 +240,11 @@ class ContextGraph:
|
||||
the score is zero, otherwise the score is the score of a implicit fail arc
|
||||
to root. The next state is always root.
|
||||
"""
|
||||
# The score of the fail arc
|
||||
score = -state.node_score
|
||||
if state.is_end:
|
||||
score = 0.0
|
||||
else:
|
||||
# The score of the fail arc
|
||||
score = -state.node_score
|
||||
return (score, self.root)
|
||||
|
||||
def draw(
|
||||
|
Loading…
x
Reference in New Issue
Block a user