NLP first interview Sledgehammer, NLTK introduction

Source: Internet
Author: User
Tags nltk

Previously downloaded a PDF, the title is "Natural language processing with Python", very interesting, plus NLP and machine learning is hot, want to take advantage of the summer vacation to dabble. So began the journey of getting started with NLP.

Installation Environment: Ubuntu14.04 Desktop version, Python version: 2.7

First step: Install NLTK, first install the PIP tool: sudo apt-get install PYTHON-PIP, install with PIP after installation nltk:sudo pip install PYTHON-NLTK.

Step two: Download all the NLTK packages and enter the Python interactive mode in the terminal.

>>> import nltk>>> nltk.download () >>> d>>> All

Then wait, the bag is very big, I am off and on for two or three days before the end.

The third step is to install the NumPy and matplotlib tools, mainly for data analysis and graphical display. Here is a reference to someone else's part:

Installation of NumPy is relatively simple, the following commands can be completed
$ sudo apt-get install python-numpy$ sudo apt-get install python-scipy
Installing matplotlib is relatively complex and requires first installing its dependent package libpng and FreeType installation libpng:
$ sudo apt-get install Libpng-dev
Install FreeType:
$ cd ~/wget http://download.savannah.gnu.org/releases/freetype/ freetype-2.4.10.tar.gztar zxvf freetype-2.4. . Tar . gz$ CD FreeType-2.4. Ten/$. /makesudomakeinstall
After the PIP is installed, you can use the following command to find the Matplotlib and view its installation status
sudo pip search matplotlib
Installing Matplotlib
sudo Install matplotlib
Complete the above steps, you can formally enter the NLTK study!

NLP first interview Sledgehammer, NLTK introduction

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.