Python Natural language processing function library NLTK from getting started to mastering

Source: Internet
Author: User
Tags nltk

1. Additions to the Python installation

If both Python2 and Python3 are installed in the Ubuntu system, enter the Python or python2 command to open the python2.x version of the console, and enter the Python3 command to open the python3.x version of the console.

Enter idle or idle2 in the new window to open the Python's own console, without installing idle then use the sudo apt install idle to install the idle program.

sudo apt install idle

  

2. Install NLTK extension function library for python2.7 under Ubuntu

Use the command sudo pip install NLTK

sudo pip install NLTK

  

3. Download data using the NLTK downloader

In the idle, enter:

Import Nltknltk.download ()

Select Collection->book to download in the pull-out downloader

Python Natural language processing function library NLTK from getting started to mastering

Related Article

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.