Deep Learning with JavaScript

Book description

In Deep Learning with JavaScript, you’ll learn to use TensorFlow.js to build deep learning models that run directly in the browser. This fast-paced book, written by Google engineers, is practical, engaging, and easy to follow. Through diverse examples featuring text analysis, speech processing, image recognition, and self-learning game AI, you’ll master all the basics of deep learning and explore advanced concepts, like retraining existing models for transfer learning and image generation.

Table of contents

  1. Copyright
  2. Brief Table of Contents
  3. Table of Contents
  4. Foreword
  5. Preface
  6. Acknowledgments
  7. About this Book
  8. About the Authors
  9. About the cover illustration
  10. Part 1. Motivation and basic concepts
    1. Chapter 1. Deep learning and JavaScript
      1. 1.1. Artificial intelligence, machine learning, neural networks, and deep learning
      2. 1.2. Why combine JavaScript and machine learning?
      3. 1.3. Why TensorFlow.js?
      4. Exercises
      5. Summary
  11. Part 2. A gentle introduction to TensorFlow.js
    1. Chapter 2. Getting started: Simple linear regression in TensorFlow.js
      1. 2.1. Example 1: Predicting the duration of a download using TensorFlow.js
      2. 2.2. Inside Model.fit(): Dissecting gradient descent from example 1
      3. 2.3. Linear regression with multiple input features
      4. 2.4. How to interpret your model
      5. Exercises
      6. Summary
    2. Chapter 3. Adding nonlinearity: Beyond weighted sums
      1. 3.1. Nonlinearity: What it is and what it is good for
      2. 3.2. Nonlinearity at output: Models for classification
      3. 3.3. Multiclass classification
      4. Exercises
      5. Summary
    3. Chapter 4. Recognizing images and sounds using convnets
      1. 4.1. From vectors to tensors: Representing images
      2. 4.2. Your first convnet
      3. 4.3. Beyond browsers: Training models faster using Node.js
      4. 4.4. Spoken-word recognition: Applying convnets on audio data
      5. Exercises
      6. Summary
    4. Chapter 5. Transfer learning: Reusing pretrained neural networks
      1. 5.1. Introduction to transfer learning: Reusing pretrained models
      2. 5.2. Object detection through transfer learning on a convnet
      3. Exercises
      4. Summary
  12. Part 3. Advanced deep learning with TensorFlow.js
    1. Chapter 6. Working with data
      1. 6.1. Using tf.data to manage data
      2. 6.2. Training models with model.fitDataset
      3. 6.3. Common patterns for accessing data
      4. 6.4. Your data is likely flawed: Dealing with problems in your data
      5. 6.5. Data augmentation
      6. Exercises
      7. Summary
    2. Chapter 7. Visualizing data and models
      1. 7.1. Data visualization
      2. 7.2. Visualizing models after training
      3. Materials for further reading and exploration
      4. Exercises
      5. Summary
    3. Chapter 8. Underfitting, overfitting, and the universal workflow of machine learning
      1. 8.1. Formulation of the temperature-prediction problem
      2. 8.2. Underfitting, overfitting, and countermeasures
      3. 8.3. The universal workflow of machine learning
      4. Exercises
      5. Summary
    4. Chapter 9. Deep learning for sequences and text
      1. 9.1. Second attempt at weather prediction: Introducing RNNs
      2. 9.2. Building deep-learning models for text
      3. 9.3. Sequence-to-sequence tasks with attention mechanism
      4. Materials for further reading
      5. Exercises
      6. Summary
    5. Chapter 10. Generative deep learning
      1. 10.1. Generating text with LSTM
      2. 10.2. Variational autoencoders: Finding an efficient and structured vec- ctor representation of images
      3. 10.3. Image generation with GANs
      4. Materials for further reading
      5. Exercises
      6. Summary
    6. Chapter 11. Basics of deep reinforcement learning
      1. 11.1. The formulation of reinforcement-learning problems
      2. 11.2. Policy networks and policy gradients: The cart-pole example
      3. 11.3. Value networks and Q-learning: The snake game example
      4. Materials for further reading
      5. Exercises
      6. Summary
  13. Part 4. Summary and closing words
    1. Chapter 12. Testing, optimizing, and deploying models
      1. 12.1. Testing TensorFlow.js models
      2. 12.2. Model optimization
      3. 12.3. Deploying TensorFlow.js models on various platforms and environments
      4. Materials for further reading
      5. Exercises
      6. Summary
    2. Chapter 13. Summary, conclusions, and beyond
      1. 13.1. Key concepts in review
      2. 13.2. Quick overview of the deep-learning workflow and algorithms in TensorFlow.js
      3. 13.3. Trends in deep learning
      4. 13.4. Pointers for further exploration
      5. Final words
  14. Appendix A. Installing tfjs-node-gpu and its dependencies
    1. A.1. Installing tfjs-node-gpu on Linux
    2. A.2. Installing tfjs-node-gpu on Windows
  15. Appendix B. A quick tutorial of tensors and operations in TensorFlow.js
    1. B.1. Tensor creation and tensor axis conventions
    2. B.2. Basic tensor operations
    3. B.3. Memory management in TensorFlow.js: tf.dispose() and tf.tidy()
    4. B.4. Calculating gradients
    5. Exercises
  16. Glossary
  17. Index
  18. List of Figures
  19. List of Tables
  20. List of Listings

Product information

  • Title: Deep Learning with JavaScript
  • Author(s): Stanley Bileschi, Shanqing Cai, Eric Nielsen
  • Release date: February 2020
  • Publisher(s): Manning Publications
  • ISBN: 9781617296178