File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
nemo_text_processing/text_normalization/hi/taggers Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -40,10 +40,18 @@ class MeasureFst(GraphFst):
4040 def __init__ (self , cardinal : GraphFst , decimal : GraphFst ):
4141 super ().__init__ (name = "measure" , kind = "classify" )
4242
43- cardinal_graph = digit | teens_and_ties | cardinal .graph_hundreds | cardinal .graph_thousands | cardinal .graph_ten_thousands | cardinal .graph_lakhs | cardinal .graph_ten_lakhs
43+ cardinal_graph = (
44+ digit
45+ | teens_and_ties
46+ | cardinal .graph_hundreds
47+ | cardinal .graph_thousands
48+ | cardinal .graph_ten_thousands
49+ | cardinal .graph_lakhs
50+ | cardinal .graph_ten_lakhs
51+ )
4452 point = pynutil .delete ("." )
4553 decimal_integers = pynutil .insert ("integer_part: \" " ) + cardinal_graph + pynutil .insert ("\" " )
46- decimal_graph = decimal_integers + point + insert_space + decimal .graph_fractional
54+ decimal_graph = decimal_integers + point + insert_space + decimal .graph_fractional
4755 unit_graph = pynini .string_file (get_abs_path ("data/measure/unit.tsv" ))
4856
4957 optional_graph_negative = pynini .closure (
You can’t perform that action at this time.
0 commit comments