Format & polish training and webui
This commit is contained in:
@@ -4,7 +4,6 @@ import re
|
||||
import cn2an
|
||||
from pypinyin import lazy_pinyin, Style
|
||||
|
||||
from text import symbols
|
||||
from text.symbols import punctuation
|
||||
from text.tone_sandhi import ToneSandhi
|
||||
|
||||
@@ -96,7 +95,6 @@ def _g2p(segments):
|
||||
tones_list = []
|
||||
word2ph = []
|
||||
for seg in segments:
|
||||
pinyins = []
|
||||
# Replace all English words in the sentence
|
||||
seg = re.sub("[a-zA-Z]+", "", seg)
|
||||
seg_cut = psg.lcut(seg)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
## origin.
|
||||
##
|
||||
## cmudict.0.6 is the fifth release of cmudict, first released as cmudict.0.1
|
||||
## in September of 1993. There was no generally available public release
|
||||
## in September of 1993. There was no generally available public release
|
||||
## of version 0.5.
|
||||
##
|
||||
## See the README in this directory before you use this dictionary.
|
||||
@@ -16,11 +16,11 @@
|
||||
## Alex Rudnicky, Jack Mostow, Roni Rosenfeld, Richard Stern,
|
||||
## Matthew Siegler, Kevin Lenzo, Maxine Eskenazi, Mosur Ravishankar,
|
||||
## Eric Thayer, Kristie Seymore, and Raj Reddy at CMU; Lin Chase at
|
||||
## LIMSI; Doug Paul at MIT Lincoln Labs; Ben Serridge at MIT SLS; Murray
|
||||
## Spiegel at Bellcore; Tony Robinson at Cambridge UK; David Bowness of
|
||||
## CAE Electronics Ltd. and CRIM; Stephen Hocking; Jerry Quinn at BNR
|
||||
## Canada, and Marshal Midden for bringing to our attention problems and
|
||||
## inadequacies with the first releases. Most special thanks to Bob Weide
|
||||
## LIMSI; Doug Paul at MIT Lincoln Labs; Ben Serridge at MIT SLS; Murray
|
||||
## Spiegel at Bellcore; Tony Robinson at Cambridge UK; David Bowness of
|
||||
## CAE Electronics Ltd. and CRIM; Stephen Hocking; Jerry Quinn at BNR
|
||||
## Canada, and Marshal Midden for bringing to our attention problems and
|
||||
## inadequacies with the first releases. Most special thanks to Bob Weide
|
||||
## for all his work on prior versions of the dictionary.
|
||||
##
|
||||
## We welcome input from users and will continue to acknowledge such input
|
||||
@@ -37,12 +37,12 @@
|
||||
## so keep your eyes open for problems and mail them to me.
|
||||
##
|
||||
## We hope this dictionary is an improvement over cmudict.0.4.
|
||||
##
|
||||
##
|
||||
## email: cmudict@cs.cmu.edu
|
||||
## web: http://www.speech.cs.cmu.edu/cgi-bin/cmudict
|
||||
## ftp: ftp://ftp.cs.cmu.edu/project/speech/dict/
|
||||
##
|
||||
## Thank you for your continued interest in the CMU Pronouncing
|
||||
## Thank you for your continued interest in the CMU Pronouncing
|
||||
## Dictionary. Further addictions and improvements are planned
|
||||
## for forthcoming releases.
|
||||
##
|
||||
|
||||
@@ -2,7 +2,6 @@ import pickle
|
||||
import os
|
||||
import re
|
||||
from g2p_en import G2p
|
||||
from string import punctuation
|
||||
|
||||
from text import symbols
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
# Convert Japanese text to phonemes which is
|
||||
# compatible with Julius https://github.com/julius-speech/segmentation-kit
|
||||
import math
|
||||
import re
|
||||
import unicodedata
|
||||
|
||||
|
||||
@@ -536,7 +536,7 @@ class ToneSandhi:
|
||||
[item.isnumeric() for item in word if item != "一"]
|
||||
):
|
||||
return finals
|
||||
# "一" between reduplication words shold be yi5, e.g. 看一看
|
||||
# "一" between reduplication words should be yi5, e.g. 看一看
|
||||
elif len(word) == 3 and word[1] == "一" and word[0] == word[-1]:
|
||||
finals[1] = finals[1][:-1] + "5"
|
||||
# when "一" is ordinal word, it should be yi1
|
||||
|
||||
Reference in New Issue
Block a user