aboSamoor / polyglot

Multilingual text (NLP) processing toolkit
http://polyglot-nlp.com
Other
2.31k stars 337 forks source link

Import error on Linux #104

Open pemba88 opened 7 years ago

pemba88 commented 7 years ago

I get the following import error with Linux

ImportError Traceback (most recent call last)

in () 1 import polyglot ----> 2 from polyglot.text import Text, Word /home/username/anaconda3/lib/python3.6/site-packages/polyglot/text.py in () 7 8 from polyglot.base import Sequence, TextFile, TextFiles ----> 9 from polyglot.detect import Detector, Language 10 from polyglot.decorators import cached_property 11 from polyglot.downloader import Downloader /home/username/anaconda3/lib/python3.6/site-packages/polyglot/detect/__init__.py in () ----> 1 from .base import Detector, Language 2 3 __all__ = ['Detector', 'Language'] /home/username/anaconda3/lib/python3.6/site-packages/polyglot/detect/base.py in () 9 10 ---> 11 from icu import Locale 12 import pycld2 as cld2 13 /home/username/anaconda3/lib/python3.6/site-packages/icu/__init__.py in () 38 39 if sys.version_info >= (3,): ---> 40 from .docs import * 41 else: 42 from docs import * /home/username/anaconda3/lib/python3.6/site-packages/icu/docs.py in () 21 # ==================================================================== 22 ---> 23 from _icu import * 24 from _icu import _install__doc__ 25 ImportError: /home/username/anaconda3/lib/python3.6/site-packages/_icu.cpython-36m-x86_64-linux-gnu.so: undefined symbol: _ZTIN6icu_5214LEFontInstanceE
KhaledSharif commented 6 years ago

Did you install libicu-dev?

sudo apt install libicu-dev