deep-learning-with-python-notebooks README

The project's README from github.com/fchollet/deep-learning-with-python-notebooks. As one markdown file: README.md.

Companion notebooks for Deep Learning with Python

This repository contains Jupyter notebooks implementing the code samples found in the book Deep Learning with Python, third edition (2025) by Francois Chollet and Matthew Watson. In addition, you will also find the legacy notebooks for the second edition (2021) and the first edition (2017).

For readability, these notebooks only contain runnable code blocks and section titles, and omit everything else in the book: text paragraphs, figures, and pseudocode. If you want to be able to follow what's going on, I recommend reading the notebooks side by side with your copy of the book.

Running the code

We recommend running these notebooks on Colab, which provides a hosted runtime with all the dependencies you will need. You can also, run these notebooks locally, either by setting up your own Jupyter environment, or using Colab's instructions for running locally.

By default, all notebooks will run on Colab's free tier GPU runtime, which is sufficient to run all code in this book. Chapter 8-18 chapters will benefit from a faster GPU if you have a Colab Pro subscription. You can change your runtime type using Runtime -> Change runtime type in Colab's dropdown menus.

Choosing a backend

The code for third edition is written using Keras 3. As such, it can be run with JAX, TensorFlow or PyTorch as a backend. To set the backend, update the backend in the cell at the top of the colab that looks like this:

import os
os.environ["KERAS_BACKEND"] = "jax"

This must be done only once per session before importing Keras. If you are in the middle running a notebook, you will need to restart the notebook session and rerun all relevant notebook cells. This can be done in using Runtime -> Restart Session in Colab's dropdown menus.

Using Kaggle data

This book uses datasets and model weights provided by Kaggle, an online Machine Learning community and platform. You will need to create a Kaggle login to run Kaggle code in this book; instructions are given in Chapter 8.

For chapters that need Kaggle data, you can login to Kaggle once per session when you hit the notebook cell with kagglehub.login(). Alternately, you can set up your Kaggle login information once as Colab secrets:

Following this approach you will only need to copy your Kaggle secret key once, though you will need to allow each notebook to access your secrets when running the relevant Kaggle code.

Table of contents

deep-learning-with-python-notebooks (fchollet/deep-learning-with-python-notebooks)

Searching Database…

Что это такое?Сопроводительные Jupyter-блокноты к книге 'Deep Learning with Python' Франсуа Шолле (и Мэтью Уотсона для 3-го издания, 2025 год) с реализацией всех её примеров кода, а также устаревшие блокноты для 2-го издания (2021) и 1-го издания (2017).
Эти блокноты заменяют книгу или дополняют её?В них есть только запускаемые блоки кода и названия разделов, без пояснительного текста, рисунков и псевдокода, так что их удобно читать параллельно с вашим экземпляром книги.
Как запустить блокноты?Рекомендуемый способ — Google Colab: там предоставляется размещённая среда со всеми предустановленными зависимостями. Можно также запускать блокноты локально, с собственной настройкой Jupyter.
Какой фреймворк для глубокого обучения нужен?Код третьего издания написан на Keras 3, который может работать с JAX, TensorFlow или PyTorch в качестве бэкенда. Выбор делается установкой переменной в начале блокнота до импорта Keras.
Нужен ли аккаунт Kaggle для некоторых глав?Да, главы, которые используют наборы данных или веса моделей, размещённые на Kaggle, требуют бесплатного входа в Kaggle. Его можно выполнять в каждой сессии через kagglehub.login() или один раз сохранить как секреты Colab.
Можно ли менять бэкенд прямо в процессе работы?Нет, без перезапуска нельзя: бэкенд задаётся один раз в начале сессии, до импорта Keras, а для смены требуется полный перезапуск сессии.
Нужен ли мощный GPU для запуска кода?Нет, бесплатной GPU-среды Colab достаточно для запуска всего кода из книги. Главы 8–18 просто быстрее работают с GPU в Colab Pro.
Какие темы охватывают главы?От математических основ нейронных сетей до классификации, архитектур CNN, сегментации изображений и обнаружения объектов, прогнозирования временных рядов, классификации текстов, трансформеров и генерации текста и изображений.
Поддерживаются ли старые издания книги?Да, устаревшие блокноты для 1-го издания (2017) и 2-го издания (2021) хранятся наряду с актуальными блокнотами для 3-го издания.
Creator
fchollet
Size
7 MB
Stars
20.3K
Updated
CommitSep 18
Age
9y
Commits · 90 Days