ตอนนี้ผมกำลังทำงานเกี่ยวกับการที่ต้องใช้ มูดูล pythainlp ครับ เพื่อมาตัดคำนะครับ เพราะว่าผมตัดใช้คู่กันกับมูดูล wordcloud ผมใช้ระบบปฏิบัติการ
วินโดว์นะครับ
ผมได้ทำการติดตั้งลองดู โดยการติดตั้งผ่าน terminal บน Pycharm ด้วยคำสั่ง
ผลลัพท์คือ
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install wordcloud
Collecting wordcloud
Using cached
https://files.pythonhosted.org/packages ... _amd64.whl
Collecting pillow (from wordcloud)
Using cached
https://files.pythonhosted.org/packages ... _amd64.whl
Collecting numpy>=1.6.1 (from wordcloud)
Using cached
https://files.pythonhosted.org/packages ... _amd64.whl
Installing collected packages: pillow, numpy, wordcloud
Successfully installed numpy-1.15.0 pillow-5.2.0 wordcloud-1.5.0
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install matplotlib
Collecting matplotlib
Downloading
https://files.pythonhosted.org/packages ... _amd64.whl (8.7MB)
100% |████████████████████████████████| 8.7MB 372kB/s
Collecting six>=1.10 (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Requirement already satisfied: numpy>=1.7.1 in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from matplotlib) (1.15.0)
Collecting python-dateutil>=2.1 (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting cycler>=0.10 (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting kiwisolver>=1.0.1 (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... _amd64.whl
Collecting pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting pytz (from matplotlib)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Requirement already satisfied: setuptools in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages\setuptools-39.1.0-py3.7.egg (from kiwisolver>=1.0.1->matplotlib) (3
9.1.0)
Installing collected packages: six, python-dateutil, cycler, kiwisolver, pyparsing, pytz, matplotlib
Successfully installed cycler-0.10.0 kiwisolver-1.0.1 matplotlib-2.2.3 pyparsing-2.2.0 python-dateutil-2.7.3 pytz-2018.5 six-1.11.0
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install pythainlp
Collecting pythainlp
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting future>=0.16.0 (from pythainlp)
Using cached
https://files.pythonhosted.org/packages ... 6.0.tar.gz
Collecting nltk>=3.2.2 (from pythainlp)
Using cached
https://files.pythonhosted.org/packages ... -3.3.0.zip
Requirement already satisfied: pytz in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from pythainlp) (2018.5)
Requirement already satisfied: six in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from pythainlp) (1.11.0)
Collecting marisa-trie<=0.7.4 (from pythainlp)
Using cached
https://files.pythonhosted.org/packages ... 7.4.tar.gz
Collecting dill (from pythainlp)
Using cached
https://files.pythonhosted.org/packages ... 8.2.tar.gz
Collecting requests (from pythainlp)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting pyreadline>=1.7.1 (from dill->pythainlp)
Using cached
https://files.pythonhosted.org/packages ... ne-2.1.zip
Collecting idna<2.8,>=2.5 (from requests->pythainlp)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Collecting certifi>=2017.4.17 (from requests->pythainlp)
Downloading
https://files.pythonhosted.org/packages ... ne-any.whl (146kB)
100% |████████████████████████████████| 153kB 4.5kB/s
Collecting chardet<3.1.0,>=3.0.2 (from requests->pythainlp)
Using cached
https://files.pythonhosted.org/packages ... ne-any.whl
Requirement already satisfied: urllib3<1.24,>=1.21.1 in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from requests->pythainlp) (1.23)
Installing collected packages: future, nltk, marisa-trie, pyreadline, dill, idna, certifi, chardet, requests, pythainlp
Running setup.py install for future ... done
Running setup.py install for nltk ... done
Running setup.py install for marisa-trie ... error
Complete output from command C:\Users\tatiy\PycharmProjects\roject_for_work\venv\Scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\tatiy\\AppData\\Local\
\Temp\\pip-install-y734ajjz\\marisa-trie\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" i
nstall --record C:\Users\tatiy\AppData\Local\Temp\pip-record-_cyfjhvm\install-record.txt --single-version-externally-managed --compile --install-headers C:\Users\tatiy\PycharmProject
s\roject_for_work\venv\include\site\python3.7\marisa-trie:
running install
running build
running build_clib
building 'libmarisa-trie' library
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools":
http://landinghub.visualstudio.com/visu ... uild-tools
----------------------------------------
Command "C:\Users\tatiy\PycharmProjects\roject_for_work\venv\Scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\tatiy\\AppData\\Local\\Temp\\pip-install-y734a
jjz\\marisa-trie\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users
\tatiy\AppData\Local\Temp\pip-record-_cyfjhvm\install-record.txt --single-version-externally-managed --compile --install-headers C:\Users\tatiy\PycharmProjects\roject_for_work\venv\i
nclude\site\python3.7\marisa-trie" failed with error code 1 in C:\Users\tatiy\AppData\Local\Temp\pip-install-y734ajjz\marisa-trie\
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
มันลง ตัว marisa ไม่ได้ครับ มันขึ้น Eror ผมได้เปิด url ลองดู
ผมจะแก้ปัญหายังไงครับ
ตอนนี้ผมกำลังทำงานเกี่ยวกับการที่ต้องใช้ มูดูล pythainlp ครับ เพื่อมาตัดคำนะครับ เพราะว่าผมตัดใช้คู่กันกับมูดูล wordcloud ผมใช้ระบบปฏิบัติการ[color=#FF0000][b]วินโดว์[/b][/color]นะครับ
ผมได้ทำการติดตั้งลองดู โดยการติดตั้งผ่าน terminal บน Pycharm ด้วยคำสั่ง
[code]pip install pythainlp[/code]
[color=#FF0000]ผลลัพท์คือ[/color]
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install wordcloud
Collecting wordcloud
Using cached https://files.pythonhosted.org/packages/23/4e/1254d26ce5d36facdcbb5820e7e434328aed68e99938c75c9d4e2fee5efb/wordcloud-1.5.0-cp37-cp37m-win_amd64.whl
Collecting pillow (from wordcloud)
Using cached https://files.pythonhosted.org/packages/39/a5/4258f77ab40d71bf7d724002a0bb166a902cb4cbdff7b866b1c3d9014547/Pillow-5.2.0-cp37-cp37m-win_amd64.whl
Collecting numpy>=1.6.1 (from wordcloud)
Using cached https://files.pythonhosted.org/packages/8b/8a/5edea6c9759b9c569542ad4da07bba0c03ffe7cfb15d8bbe59b417e99a84/numpy-1.15.0-cp37-none-win_amd64.whl
Installing collected packages: pillow, numpy, wordcloud
Successfully installed numpy-1.15.0 pillow-5.2.0 wordcloud-1.5.0
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install matplotlib
Collecting matplotlib
Downloading https://files.pythonhosted.org/packages/eb/b7/4a5ae8f5fb745109a9425c4118c449447c8119ded7b401c655e86def677a/matplotlib-2.2.3-cp37-cp37m-win_amd64.whl (8.7MB)
100% |████████████████████████████████| 8.7MB 372kB/s
Collecting six>=1.10 (from matplotlib)
Using cached https://files.pythonhosted.org/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Requirement already satisfied: numpy>=1.7.1 in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from matplotlib) (1.15.0)
Collecting python-dateutil>=2.1 (from matplotlib)
Using cached https://files.pythonhosted.org/packages/cf/f5/af2b09c957ace60dcfac112b669c45c8c97e32f94aa8b56da4c6d1682825/python_dateutil-2.7.3-py2.py3-none-any.whl
Collecting cycler>=0.10 (from matplotlib)
Using cached https://files.pythonhosted.org/packages/f7/d2/e07d3ebb2bd7af696440ce7e754c59dd546ffe1bbe732c8ab68b9c834e61/cycler-0.10.0-py2.py3-none-any.whl
Collecting kiwisolver>=1.0.1 (from matplotlib)
Using cached https://files.pythonhosted.org/packages/7c/be/7ae355b45699460e369ebf88d86058fca26827933974cc3f6b6b7800a324/kiwisolver-1.0.1-cp37-none-win_amd64.whl
Collecting pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 (from matplotlib)
Using cached https://files.pythonhosted.org/packages/6a/8a/718fd7d3458f9fab8e67186b00abdd345b639976bc7fb3ae722e1b026a50/pyparsing-2.2.0-py2.py3-none-any.whl
Collecting pytz (from matplotlib)
Using cached https://files.pythonhosted.org/packages/30/4e/27c34b62430286c6d59177a0842ed90dc789ce5d1ed740887653b898779a/pytz-2018.5-py2.py3-none-any.whl
Requirement already satisfied: setuptools in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages\setuptools-39.1.0-py3.7.egg (from kiwisolver>=1.0.1->matplotlib) (3
9.1.0)
Installing collected packages: six, python-dateutil, cycler, kiwisolver, pyparsing, pytz, matplotlib
Successfully installed cycler-0.10.0 kiwisolver-1.0.1 matplotlib-2.2.3 pyparsing-2.2.0 python-dateutil-2.7.3 pytz-2018.5 six-1.11.0
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
(venv) C:\Users\tatiy\PycharmProjects\roject_for_work>pip install pythainlp
Collecting pythainlp
Using cached https://files.pythonhosted.org/packages/dc/57/8ed5cf64a032956b92e0170992de1dd15b4e73933079f74a62759a67dee3/pythainlp-1.6.0.7-py2.py3-none-any.whl
Collecting future>=0.16.0 (from pythainlp)
Using cached https://files.pythonhosted.org/packages/00/2b/8d082ddfed935f3608cc61140df6dcbf0edea1bc3ab52fb6c29ae3e81e85/future-0.16.0.tar.gz
Collecting nltk>=3.2.2 (from pythainlp)
Using cached https://files.pythonhosted.org/packages/50/09/3b1755d528ad9156ee7243d52aa5cd2b809ef053a0f31b53d92853dd653a/nltk-3.3.0.zip
Requirement already satisfied: pytz in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from pythainlp) (2018.5)
Requirement already satisfied: six in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from pythainlp) (1.11.0)
Collecting marisa-trie<=0.7.4 (from pythainlp)
Using cached https://files.pythonhosted.org/packages/3f/67/ca798a3f931a7aa192c40d148313693eccb843ddb536144cbe994311020c/marisa-trie-0.7.4.tar.gz
Collecting dill (from pythainlp)
Using cached https://files.pythonhosted.org/packages/6f/78/8b96476f4ae426db71c6e86a8e6a81407f015b34547e442291cd397b18f3/dill-0.2.8.2.tar.gz
Collecting requests (from pythainlp)
Using cached https://files.pythonhosted.org/packages/65/47/7e02164a2a3db50ed6d8a6ab1d6d60b69c4c3fdf57a284257925dfc12bda/requests-2.19.1-py2.py3-none-any.whl
Collecting pyreadline>=1.7.1 (from dill->pythainlp)
Using cached https://files.pythonhosted.org/packages/bc/7c/d724ef1ec3ab2125f38a1d53285745445ec4a8f19b9bb0761b4064316679/pyreadline-2.1.zip
Collecting idna<2.8,>=2.5 (from requests->pythainlp)
Using cached https://files.pythonhosted.org/packages/4b/2a/0276479a4b3caeb8a8c1af2f8e4355746a97fab05a372e4a2c6a6b876165/idna-2.7-py2.py3-none-any.whl
Collecting certifi>=2017.4.17 (from requests->pythainlp)
Downloading https://files.pythonhosted.org/packages/16/1f/50d729c104b21c1042aa51560da6141d1cab476ba7015d92b2111c8db841/certifi-2018.8.13-py2.py3-none-any.whl (146kB)
100% |████████████████████████████████| 153kB 4.5kB/s
Collecting chardet<3.1.0,>=3.0.2 (from requests->pythainlp)
Using cached https://files.pythonhosted.org/packages/bc/a9/01ffebfb562e4274b6487b4bb1ddec7ca55ec7510b22e4c51f14098443b8/chardet-3.0.4-py2.py3-none-any.whl
Requirement already satisfied: urllib3<1.24,>=1.21.1 in c:\users\tatiy\pycharmprojects\roject_for_work\venv\lib\site-packages (from requests->pythainlp) (1.23)
Installing collected packages: future, nltk, marisa-trie, pyreadline, dill, idna, certifi, chardet, requests, pythainlp
Running setup.py install for future ... done
Running setup.py install for nltk ... done
Running setup.py install for marisa-trie ... error
Complete output from command C:\Users\tatiy\PycharmProjects\roject_for_work\venv\Scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\tatiy\\AppData\\Local\
\Temp\\pip-install-y734ajjz\\marisa-trie\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" i
nstall --record C:\Users\tatiy\AppData\Local\Temp\pip-record-_cyfjhvm\install-record.txt --single-version-externally-managed --compile --install-headers C:\Users\tatiy\PycharmProject
s\roject_for_work\venv\include\site\python3.7\marisa-trie:
running install
running build
running build_clib
building 'libmarisa-trie' library
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools
----------------------------------------
[color=#FF0000]Command "C:\Users\tatiy\PycharmProjects\roject_for_work\venv\Scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\tatiy\\AppData\\Local\\Temp\\pip-install-y734a
jjz\\marisa-trie\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users
\tatiy\AppData\Local\Temp\pip-record-_cyfjhvm\install-record.txt --single-version-externally-managed --compile --install-headers C:\Users\tatiy\PycharmProjects\roject_for_work\venv\i
nclude\site\python3.7\marisa-trie" failed with error code 1 in C:\Users\tatiy\AppData\Local\Temp\pip-install-y734ajjz\marisa-trie\[/color]
[color=#FFBF40]You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.[/color]
มันลง ตัว marisa ไม่ได้ครับ มันขึ้น Eror ผมได้เปิด url ลองดู
[attachment=0]Capture.PNG[/attachment]
ผมจะแก้ปัญหายังไงครับ