In this section, we will explore changes we can make to the model architecture and other settings to improve author classification performance. We will carry out two experiments, and, for both of these two experiments, we will increase the number of most frequent words from 500 to 1,500 and increase the length of the sequences of integers from 300 to 400. For both experiments, we will also add a dropout layer after the pooling layer.
Performance optimization tips and best practices
Experimenting with reduced batch size
The code that we'll be using for this experiment is as follows:
# Model architecture
model <- keras_model_sequential() %>%
layer_embedding(input_dim = 1500,
output_dim...