In this section, we will start with a simple LSTM network architecture and look at calculations to arrive at the number of parameters. Subsequently, we will compile the model.
Creating a long short-term memory network model
LSTM network architecture
We will start with a simple flow chart of the LSTM network architecture, as shown in the following screenshot:
The preceding flow chart for the LSTM network highlights the layers in the architecture and activation functions used. In the LSTM layer, the tanh activation function is used which is the default activation function for the layer. In the dense layer, the sigmoid activation function is used.
Let's have a look at the following code and summary of the model:
# Model...