MP6: RNN¶
This MP will use pytorch, which is an extremely powerful and flexible neural net training package.
NOTE EXTENDED DEADLINE: Due date is Wednesday, 12/8, 11:59pm.
Pytorch is intentionally easy to learn, but even so, it’s worth spending some time with the pytorch tutorial.
In this MP, you will train an LSTM voice conversion system.
mp6.zip contains the code. You should download the code, unzip it into some directory, and then type
jupyter-labto get started.mp6_notebook.html is an example of what the Jupyter notebook will look like, once you’ve finished everything.
The MP uses a lot of torch-specific functions. You can find documentation for all of those functions here.
Your
LineEar.__init__method will use torch.nn.parameter.Parameter.Your
LineEar.forwardmethod will use torch.matmul.Your module
EllEssTeeEmmwill put torch.nn.LSTMCells. into two torch.nn.ModuleLists – one calledself.forward_layers, one calledself.reverse_layers.Your module
GeeArrYouwill put torch.nn.GRUCells. into two torch.nn.ModuleLists – one calledself.forward_layers, one calledself.reverse_layers.Your
Encoder.__init__,Decoder.__init__, andPostnet.__init__will each put Conv1d, BatchNorm1d, and ReLU layers into a torch.nn.ModuleLists – calledself.convolutions. They will then create anEllEssTeeEmmmodule calledself.recurrent, and aLineEarcalledself.fc_projection.
python grade.pyis how you will grade your code on your local machine.When it works on your machine, then you can try uploading only the file
submitted.pyto the MP4 assignment on Gradescope.
