Comparing LSTMs to LSTMs with peephole connections and GRUs
Now we will compare LSTMs to LSTMs with peepholes and GRUs in the text generation task. This will help us to compare how well different models (LSTMs with peepholes and GRUs) perform in terms of perplexity as well as the quality of the generated text. This is available as an exercise in lstm_extensions.ipynb
located in the ch8
folder.
Standard LSTM
First, we will reiterate the components of a standard LSTM. We will not repeat the code for standard LSTMs as it is identical to what we discussed previously. Finally, we will see some text generated by an LSTM.
Review
Here we will revisit what a standard LSTM looks like. As we already mentioned, an LSTM consists of the following:
Input gate: This decides how much of the current input is written to the cell state
Forget gate: This decides how much of the previous cell state is written to the current cell state
Output gate: This decides how much information from the cell state is exposed to...