Skip to content

Commit

Permalink
parse orth fix (#1510)
Browse files Browse the repository at this point in the history
Co-authored-by: Atanas Gruev <agruev@ccx-00.apptek.local>
  • Loading branch information
AtanasGruev and Atanas Gruev authored Mar 27, 2024
1 parent 5c1e241 commit ac7e7a7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion returnn/util/basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -1713,7 +1713,10 @@ def parse_orthography_into_symbols(
else: # not in_special
if square_brackets_for_specials and c == "[":
in_special = 1
ret += ["["]
if ret and not ret[-1]:
ret[-1] += c
else:
ret += ["["]
else:
if word_based:
if c.isspace():
Expand Down

0 comments on commit ac7e7a7

Please sign in to comment.