TensorFlow.js

Tutorials & Guides

Tutorials

Core Concepts in TensorFlow.js

Learn about core concepts in TensorFlow.js such as tensors, operations, models, layers and training. Also learn a few useful tips about memory management and writing "tidy" code.

Training First Steps: Fitting a Curve to Synthetic Data

This tutorial demonstrates building a small toy model completely from scratch using TensorFlow.js operations. We will fit a curve to some synthetic data that we generate using a polynomial function.

Training on images — Recognizing Handwritten Digits with a Convolutional Neural Network

This tutorial shows how to build a convolutional neural network to recognize handwritten digits in images (MNIST). We will use the TensorFlow.js layers API to construct, train, and evaluate the model.

Transfer learning - Train a neural network to predict from webcam data

This tutorial explains how to train a neural network to make predictions from webcam data. We'll use those predictions to play Pac-Man!

How to import a Keras Model into TensorFlow.js

This tutorial explains how to convert and serve an existing Keras model to run in the browser.

How to import a TensorFlow SavedModel into TensorFlow.js

Developer Preview: This tutorial explains how to convert and serve an existing TensorFlow SavedModel to run in the browser.

Guides

TensorFlow.js Layers API for Keras Users

This guide explains the similarities and differences between the Layers API of TensorFlow.js and Keras.