Python的Nltk包安装使用
来源:互联网 发布:照片生成器软件 编辑:程序博客网 时间:2024/06/16 05:04
Python的Nltk包
安装方法
http://www.nltk.org/install.html
使用
- >>>
import nltk - >>>
nltk.download()
nltk.download() 太慢了,所以我先手动下载好,解压,放到 /usr/local/share/nltk_data目录下
[root@10-10-198-186 nltk_data]# pwd
/usr/local/share/nltk_data
[root@10-10-198-186 nltk_data]# ls
chunkers corpora grammers help stemmers taggers tokenizers
即可
执行下面测试
- >>>
from nltk.book import * - ***
Introductory Examples for the NLTK Book *** - Loading
text1, ..., text9 and sent1, ..., sent9 - Type
the name of the text or sentence to view it. - Type:
'texts()' or 'sents()' to list the materials. - text1:
Moby Dick by Herman Melville 1851 - text2:
Sense and Sensibility by Jane Austen 1811 - text3:
The Book of Genesis - text4:
Inaugural Address Corpus - text5:
Chat Corpus - text6:
Monty Python and the Holy Grail - text7:
Wall Street Journal - text8:
Personals Corpus - text9:
The Man Who Was Thursday by G . K . Chesterton 1908 - >>>
说明成功
0 0
- Python的Nltk包安装使用
- Python安装nltk以及里面一些包的使用
- Windows下安装Python的numpy包和nltk
- python Nltk 自然语言安装包安装教程
- Python安装nltk使用Ngram
- mac下 安装python包numpy, nltk
- python nltk库的安装和简单使用
- nltk在python中的安装,以及nltk的data库
- win10下使用nltk的brown的词性tag包报错以及处理方法安装nltk相应包的操作办法
- python中nltk的下载安装方式
- python中nltk的下载安装方式
- 关于Python-NLTK安装的一些事儿
- Python安装nltk模块
- windows7 安装python +nltk
- Python 使用nltk计算词的搭配
- Python自然语言处理(NLP)入门教程(NLTK库的安装和使用)
- 【Python&NLP】Python入门、自然语言处理以及nltk的安装
- Mac安装nltk后在python 3的IDLE中import nltk报错
- C++ 排列组合
- Monkeyrunner
- 安卓 Bitmap类抓某个像素点的RGB
- Large Scale Dist…
- 添加资源文件遇到的问题
- Python的Nltk包安装使用
- Linux screen
- python 连接mysql
- python将句子中两个子串位置互换的…
- 重要的Python库(利用Python进行数据分析笔记)
- scala 重点语法总结
- 关于Hadoop的GenericOptionsParser…
- 如何利用Nodexl画图——以绘制…
- 3.11