bootphon / phonemizer

Simple text to phones converter for multiple languages
https://bootphon.github.io/phonemizer/
GNU General Public License v3.0
1.23k stars 172 forks source link

No module named 'segments' #52

Closed t-duan closed 4 years ago

t-duan commented 4 years ago

Hi, I tried to install Phonemizer from sources, when I run "python setup.py", I got the following error: Traceback (most recent call last): File "setup.py", line 21, in import phonemizer File "/home/duan/phonemizer/phonemizer/init.py", line 17, in from .phonemize import phonemize File "/home/duan/phonemizer/phonemizer/phonemize.py", line 27, in from phonemizer.backend import ( File "/home/duan/phonemizer/phonemizer/backend/init.py", line 19, in from .segments import SegmentsBackend File "/home/duan/phonemizer/phonemizer/backend/segments.py", line 20, in import segments ModuleNotFoundError: No module named 'segments'

mmmaat commented 4 years ago

Hi, thanks for reporting. I guess this is due to a recent change in the import system (https://github.com/bootphon/phonemizer/blob/master/CHANGELOG.md#phonemizer-221), I'll fix it soon.

If you can't wait, just edit setup.py: remove the line import phonemizer and change the line version=phonemizer.__version__ to version='2.2.1'.

t-duan commented 4 years ago

Ok, thank you very much!