Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not reproduce the example #160

Open
JohnHerry opened this issue Oct 13, 2023 · 0 comments
Open

Can not reproduce the example #160

JohnHerry opened this issue Oct 13, 2023 · 0 comments

Comments

@JohnHerry
Copy link

Thanks for the job.

I have download the mandarin cedict file and tried the example code

`from epitran.backoff import Backoff

backoff = Backoff(['hin-Deva', 'eng-Latn', 'cmn-Hans'], cedict_file=‘cedict_1_0_ts_utf-8_mdbg.txt')
backoff.transliterate('हिन्दी')
'ɦindiː'
backoff.transliterate('English')
'ɪŋɡlɪʃ'
backoff.transliterate('中文')
'ʈ͡ʂoŋwən'`

But when I use backoff to transliterate an English word, It raise Exception:

"""
arpa_text = arpa_text.splitlines()[0]
Index out of range
"""

When I input Chinese, it can convert output of the form PinYin but not IPA.

How to make IPA output when my input is a sentence of bilingural-English-Chinese characters?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant