Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Python Natural Language Processing

You're reading from  Python Natural Language Processing

Product type Book
Published in Jul 2017
Publisher Packt
ISBN-13 9781787121423
Pages 486 pages
Edition 1st Edition
Languages
Toc

Table of Contents (13) Chapters close

Preface 1. Introduction 2. Practical Understanding of a Corpus and Dataset 3. Understanding the Structure of a Sentences 4. Preprocessing 5. Feature Engineering and NLP Algorithms 6. Advanced Feature Engineering and NLP Algorithms 7. Rule-Based System for NLP 8. Machine Learning for NLP Problems 9. Deep Learning for NLU and NLG Problems 10. Advanced Tools 11. How to Improve Your NLP Skills 12. Installation Guide

Handling corpus-raw text

In this section, we will see how to get the raw text and, in the following section, we will preprocess text and identify the sentences.

The process for this section is given in Figure 4.1:

Figure 4.1: Process of handling corpus-raw text

Getting raw text

In this section, we will use three sources where we can get the raw text data.

The following are the data sources:

  • Raw text file
  • Define raw data text inside a script in the form of a local variable
  • Use any of the available corpus from nltk

Let's begin:

  • Raw text file access: I have a .txt file saved on my local computer which contains text data in the form of a paragraph. I want to read the content of that file and then load the content as the...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime}