Skip to content

TensorFlow in 60 Minutes

TL;DR: Learn how to build machine learning models using TensorFlow in 60 minutes with hands-on examples including neural networks and structural time series forecasting.

Tutorial in 30 Seconds#

TensorFlow is an open-source machine learning framework from Google for building and training neural networks and probabilistic models.

Key capabilities:

  • Tensors and automatic differentiation: Immutable multi-dimensional arrays optimized for CPUs, GPUs, and TPUs with efficient gradient computation
  • Keras API: High-level interface for rapidly building and training neural networks
  • TensorFlow Probability: Probabilistic programming for Bayesian inference and uncertainty quantification
  • Interpretable models: Structural decomposition reveals which components drive predictions

This tutorial's goal is to show you in 60 minutes:

  • The core APIs of TensorFlow (tensors, variables, automatic differentiation)
  • How to build and train neural networks with Keras
  • Probabilistic modeling with TensorFlow Probability distributions and Bayesian inference

Official References#

Tutorial Content#

This tutorial includes all the code, notebooks, and Docker containers in tutorials/tensorflow

  • README.md: Instructions and setup for the tutorial environment
  • A Docker system to build and run the environment using our standardized approach
  • tensorflow.API.ipynb: Tutorial notebook focusing on core APIs and fundamentals
  • tensorflow.example.ipynb: Advanced end-to-end structural time series forecasting example
    • Data Generation: We generate a realistic synthetic daily time series that combines:
    • Model Building: We approximate the posterior over model parameters using Variational Inference (VI)
    • Forecasting and Evaluation
  • tensorflow_utils.py: Utility functions