Keras Functional API
Explore the Keras Functional API to build advanced deep learning models that feature multiple inputs, outputs, and shortcut connections. Understand how to implement residual blocks like those in ResNet to improve training stability and model performance. This lesson guides you through defining flexible network architectures beyond the limitations of Sequential models.
We'll cover the following...
A Sequential Keras model consists of a sequence of layers arranged one after the other. We employ the Sequential class to create DL models when each model layer has only one input tensor and one output tensor. Consider, for example, the case when our layers aren’t just stacked on each other but also have multiple inputs or multiple outputs. The Sequential class is unable to build such DL models. Keras provides the functional API to build models that have input or output branches. Let’s explore the details of the functional API of Keras.
Example: Residual block
Consider the following part of a deep neural network architecture where we feed the input