Learning TensorFlow.js: Powerful Machine Learning in JavaScript
Given the demand for AI and the ubiquity of JavaScript, TensorFlow.js was inevitable. With this Google framework, seasoned AI veterans and web developers alike can help propel the future of AI-driven websites. In this guide, author Gant Laborde (Google Developer Expert in machine learning and the web) provides a hands-on end-to-end approach to TensorFlow.js fundamentals for a broad technical audience that includes data scientists, engineers, web developers, students, and researchers.

You'll begin by working through some basic examples in TensorFlow.js before diving deeper into neural network architectures, DataFrames, TensorFlow Hub, model conversion, transfer learning, and more. Once you finish this book, you'll know how to build and deploy production-ready deep learning systems with TensorFlow.js.

  • Explore tensors, the most fundamental structure of machine learning
  • Convert data into tensors and back with a real-world example
  • Combine AI with the web using TensorFlow.js
  • Use resources to convert, train, and manage machine learning data
  • Build and train your own training models from scratch
1138954413
Learning TensorFlow.js: Powerful Machine Learning in JavaScript
Given the demand for AI and the ubiquity of JavaScript, TensorFlow.js was inevitable. With this Google framework, seasoned AI veterans and web developers alike can help propel the future of AI-driven websites. In this guide, author Gant Laborde (Google Developer Expert in machine learning and the web) provides a hands-on end-to-end approach to TensorFlow.js fundamentals for a broad technical audience that includes data scientists, engineers, web developers, students, and researchers.

You'll begin by working through some basic examples in TensorFlow.js before diving deeper into neural network architectures, DataFrames, TensorFlow Hub, model conversion, transfer learning, and more. Once you finish this book, you'll know how to build and deploy production-ready deep learning systems with TensorFlow.js.

  • Explore tensors, the most fundamental structure of machine learning
  • Convert data into tensors and back with a real-world example
  • Combine AI with the web using TensorFlow.js
  • Use resources to convert, train, and manage machine learning data
  • Build and train your own training models from scratch
55.99 In Stock
Learning TensorFlow.js: Powerful Machine Learning in JavaScript

Learning TensorFlow.js: Powerful Machine Learning in JavaScript

by Gant Laborde
Learning TensorFlow.js: Powerful Machine Learning in JavaScript

Learning TensorFlow.js: Powerful Machine Learning in JavaScript

by Gant Laborde

Paperback

$55.99 
  • SHIP THIS ITEM
    In stock. Ships in 1-2 days.
  • PICK UP IN STORE

    Your local store may have stock of this item.

Related collections and offers


Overview

Given the demand for AI and the ubiquity of JavaScript, TensorFlow.js was inevitable. With this Google framework, seasoned AI veterans and web developers alike can help propel the future of AI-driven websites. In this guide, author Gant Laborde (Google Developer Expert in machine learning and the web) provides a hands-on end-to-end approach to TensorFlow.js fundamentals for a broad technical audience that includes data scientists, engineers, web developers, students, and researchers.

You'll begin by working through some basic examples in TensorFlow.js before diving deeper into neural network architectures, DataFrames, TensorFlow Hub, model conversion, transfer learning, and more. Once you finish this book, you'll know how to build and deploy production-ready deep learning systems with TensorFlow.js.

  • Explore tensors, the most fundamental structure of machine learning
  • Convert data into tensors and back with a real-world example
  • Combine AI with the web using TensorFlow.js
  • Use resources to convert, train, and manage machine learning data
  • Build and train your own training models from scratch

Product Details

ISBN-13: 9781492090793
Publisher: O'Reilly Media, Incorporated
Publication date: 06/01/2021
Pages: 338
Product dimensions: 7.00(w) x 9.10(h) x 0.90(d)

About the Author

Gant Laborde is a proud New Orleans native and adventurous engineer. His accolades include being an owner of Infinite Red, mentor, adjunct professor, published author, and award-winning speaker. As a developer for over 20 years, he has spoken at hundreds of conferences and trained numerous developers. As a Google Developer Expert in both machine learning and the web, he covers TensorFlow.js from multiple perspectives to make the concept approachable. Follow Gant’s adventures at http://gantlaborde.com/

Table of Contents

Foreword xv

Preface xvii

1 Alls Magic 1

The Path of AI in JavaScript 2

What Is Intelligence? 3

The History of AI 4

The Neural Network 6

Today's AI 8

Why TensorFlow.js? 9

Significant Support 9

Online Ready 10

Offline Ready 10

Privacy 10

Diversity 10

Types of Machine Learning 11

Quick Definition: Supervised Learning 11

Quick Definition: Unsupervised Learning 12

Quick Definition: Semisupervised Learning 12

Quick Definition: Reinforcement Learning 13

Information Overload 13

AI Is Everywhere 14

A Tour of What Frameworks Provide 14

What Is a Model? 16

In This Book 17

Associated Code 18

Chapter Sections 20

Common AI/ML Terminology 20

Chapter Review 24

Review Questions 24

2 Introducing TensorFlow.js 25

Hello, TensorFlow.js 25

Leveraging TensorFlow.js 27

Let's Get TensorFlow.js Ready 28

Getting Set Up with TensorFlow.js in the Browser 29

Using NPM 29

Including a Script Tag 29

Getting Set Up with TensorFlow.js Node 30

Verifying TensorFlow.js Is Working 32

Download and Run These Examples 32

Let's Use Some Real TensorFlow.js 34

The Toxicity Classifier 35

Loading the Model 40

Classifying 42

Try It Yourself 42

Chapter Review 42

Chapter Challenge: Truck Alert! 43

Review Questions 44

3 Introducing Tensors 45

Why Tensors? 45

Hello, Tensors 46

Creating Tensors 47

Tensors for Data Exercises 50

Tensors on Tour 53

Tensors Provide Speed 53

Tensors Provide Direct Access 53

Tensors Batch Data 54

Tensors in Memory 54

Deallocating Tensors 54

Automatic Tensor Cleanup 55

Tensors Come Home 57

Retrieving Tensor Data 58

Tensor Manipulation 60

Tensors and Mathematics 60

Recommending Tensors 61

Chapter Review 66

Chapter Challenge: What Makes You So Special? 66

Review Questions 67

4 Image Tensors 69

Visual Tensors 70

Quick Image Tensors 72

JPGs and PNGs and GIFs, Oh My! 76

Browser: Tensor to Image 76

Browser: Image to Tensor 77

Node: Tensor to Image 80

Node: Image to Tensor 83

Common Image Modifications 85

Mirroring Image Tensors 85

Resizing Image Tensors 89

Cropping Image Tensors 91

New Image Tools 93

Chapter Review 93

Chapter Challenge: Sorting Chaos 93

Review Questions 94

5 Introducing Models 97

Loading Models 98

Loading Models Via Public URL 98

Loading Models from Other Locations 101

Our First Consumed Model 101

Loading, Encoding, and Asking a Model 102

Interpreting the Results 105

Cleaning the Board After 107

Our First TensorFlow Hub Model 107

Exploring TFHub 107

Wiring Up Inception v3 108

Our First Overlayed Model 110

The Localization Model 111

Labeling the Detection 113

Chapter Review 116

Chapter Challenge: Cute Faces 116

Review Questions 117

6 Advanced Models and UI 119

MobileNet Again 120

SSD MobileNet 122

Bounding Outputs 124

Reading Model Outputs 124

Displaying All Outputs 126

Detection Cleanup 127

Quality Checking 128

IoUs and NMS 129

Adding Text Overlays 134

Solving Low Contrast 134

Solving Draw Order 136

Connecting to a Webcam 138

Moving from Image to Video 139

Activating a Webcam 140

Drawing Detections 141

Chapter Review 142

Chapter Challenge: Top Detective 142

Review Questions 143

7 Model-Making Resources 145

Out-of-Network Model Shopping 146

Model Zoos 146

Converting Models 146

Your First Customized Model 149

Meet Teachable Machine 150

Use Teachable Machine 151

Gathering Data and Training 152

Verifying the Model 155

Machine Learning Gotchas 157

Small Amounts of Data 157

Poor Data 157

Data Bias 158

Overfitting 158

Underfitting 158

Datasets Shopping 159

The Popular Datasets 161

Chapter Review 162

Chapter Challenge: R.I.P. You Will Be MNIST 162

Review Questions 163

8 Training Models 165

Training 101 166

Data Prep 167

Design a Model 167

Identify Learning Metrics 169

Task the Model with Training 171

Put It All Together 171

Nonlinear Training 101 174

Gathering the Data 175

Adding Activations to Neurons 175

Watching Training 178

Improving Training 180

Chapter Review 185

Chapter Challenge: The Model Architect 185

Review Questions 186

9 Classification Models and Data Analysis 187

Classification Models 188

The Titanic 190

Titanic Dataset 190

Danfo.js 191

Preparing for the Titanic 192

Training on Titanic Data 197

Feature Engineering 199

Dnotebook 200

Titanic Visuals 201

Creating Features (aka Preprocessing) 204

Feature Engineered Training Results 207

Reviewing Results 207

Chapter Review 207

Chapter Challenge: Ship Happens 208

Review Questions 209

10 Image Training 211

Understanding Convolutions 212

Convolutions Quick Summary 213

Adding Convolution Layers 215

Understanding Max Pooling 216

Max Pooling Quick Summary 216

Adding Max Pooling Layers 218

Training Image Classification 218

Handling Image Data 220

The Sorting Hat 220

Getting Started 222

Converting Folders of Images 224

The CNN Model 227

Training and Saving 231

Testing the Model 232

Building a Sketchpad 232

Reading the Sketchpad 233

Chapter Review 236

Chapter Challenge: Saving the Magic 236

Review Questions 237

11 Transfer Learning 239

How Does Transfer Learning Work? 240

Transfer Learning Neural Networks 241

Easy MobileNet Transfer Learning 242

TensorFlow Hub Check, Mate! 244

Utilizing Layers Models for Transfer Learning 248

Shaving Layers on MobileNet 249

Layers Feature Model 250

A Unified Model 251

No Training Needed 251

Easy KNN: Bunnies Versus Sports Cars 253

Chapter Review 256

Chapter Challenge: Warp-Speed Learning 256

Review Questions 257

12 Dicify: Capstone Project 259

A Dicey Challenge 260

The Plan 261

The Data 261

The Training 263

The Website 263

Generating Training Data 263

Training 268

The Site Interface 269

Cut into Dice 270

Reconstruct the Image 272

Chapter Review 274

Chapter Challenge: Easy as 01, 10, 11 275

Review Questions 276

Afterword 277

A Chapter Review Answers 281

B Chapter Challenge Answers 289

C Rights and Licenses 299

Index 303

From the B&N Reads Blog

Customer Reviews