In this project, I built a neural network for machine translation (English -> French). I built and trained a sequence to sequence model on a dataset of English and French sentences that can translate new sentences from English to French. The model was trained on my own laptop with a Nvidia M1200 GPU. In the end, we reached ~95% accuracy. And here is an example of the translation:
Input
English Words: [‘he’, ‘saw’, ‘a’, ‘old’, ‘yellow’, ‘truck’, ‘.’]
Prediction
French Words: [‘il’, ‘a’, ‘vu’, ‘un’, ‘vieux’, ‘camion’, ‘jaune’, ‘.’, ‘<EOS>’]
As I do not know French, I checked Google Translate and it looks like the translation is pretty good.
The full project with code can be found here:
dlnd_language_translation.html