In this example, we will work with a recurrent neural network specialized in character sequences, or the char RNN model.
We will feed this neural network with a series of musical tunes, the Bach Goldberg Variations, expressed in a character based format, and write a sample piece of music based on the learned structures.
Note that this examples owes many ideas and concepts to the paper Visualizing and Understanding Recurrent Networks (https://arxiv.org/abs/1506.02078) and the article titled The Unreasonable Effectiveness of recurrent neural networks, available at (http://karpathy.github.io/2015/05/21/rnn-effectiveness/).
As we previously saw, Char RNN models work with character sequences. ...