Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Deep Learning with fastai Cookbook
  • Table Of Contents Toc
  • Feedback & Rating feedback
Deep Learning with fastai Cookbook

Deep Learning with fastai Cookbook

By : Ryan
4.5 (15)
close
close
Deep Learning with fastai Cookbook

Deep Learning with fastai Cookbook

4.5 (15)
By: Ryan

Overview of this book

fastai is an easy-to-use deep learning framework built on top of PyTorch that lets you rapidly create complete deep learning solutions with as few as 10 lines of code. Both predominant low-level deep learning frameworks, TensorFlow and PyTorch, require a lot of code, even for straightforward applications. In contrast, fastai handles the messy details for you and lets you focus on applying deep learning to actually solve problems. The book begins by summarizing the value of fastai and showing you how to create a simple 'hello world' deep learning application with fastai. You'll then learn how to use fastai for all four application areas that the framework explicitly supports: tabular data, text data (NLP), recommender systems, and vision data. As you advance, you'll work through a series of practical examples that illustrate how to create real-world applications of each type. Next, you'll learn how to deploy fastai models, including creating a simple web application that predicts what object is depicted in an image. The book wraps up with an overview of the advanced features of fastai. By the end of this fastai book, you'll be able to create your own deep learning applications using fastai. You'll also have learned how to use fastai to prepare raw datasets, explore datasets, train deep learning models, and deploy trained models.
Table of Contents (10 chapters)
close
close

Chapter 4: Training Models with Text Data

In Chapter 3, Training Models with Tabular Data, you went through a series of recipes that demonstrated how to use the facilities of fastai to train deep learning models on tabular data. In this chapter, we will examine how to take advantage of the fastai framework to train deep learning models on text datasets.

To explore deep learning with text data in fastai, we will start by taking a pre-trained language model (that is, a model that, when given a phrase, predicts what words come next) and fine-tuning it with the IMDb curated dataset. We will then use the resulting fine-tuned language model to create a text classifier model for the movie review use case represented by the IMDb dataset. The text classifier predicts the class of a phrase; in the movie review use case, it predicts whether a given phrase is positive or negative.

Finally, we apply the same approach to a standalone (that is, non-curated) text dataset of Covid-related tweets...

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech

Create a Note

Modal Close icon
You need to login to use this feature.
notes
bookmark search playlist download font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Delete Note

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Edit Note

Modal Close icon
Write a note (max 255 characters)
Cancel
Update Note

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY