Machine Learning 2 DS 4420 - Spring 2020 Sequence-2-sequence models - - PowerPoint PPT Presentation
Machine Learning 2 DS 4420 - Spring 2020 Sequence-2-sequence models - - PowerPoint PPT Presentation
Machine Learning 2 DS 4420 - Spring 2020 Sequence-2-sequence models Byron C. Wallace Today Learning to map between sequences Today Learning to map between sequences Input x 1 x 2 x T-1 x T Output y 1 y 2 y T-1 y T MAGIC
Today
- Learning to map between sequences
Today
- Learning to map between sequences
x1 x2 xT-1 xT …
Input
x1 x2 xT-1 xT …
Input
y1 y2 yT-1 yT …
Output
MAGIC
Motivating Example: Translation
x1 x2 xT-1 xT …
English
y1 y2 yT-1 yT …
Spanish
MAGIC
where is the library? donde esta la bibliotheque?
Motivating Example: Sequence Captioning
Example credit: https://towardsdatascience.com/understanding-encoder-decoder-sequence-to-sequence-model-679e04af4346
Input
Motivating Example: Sequence Captioning
Example credit: https://towardsdatascience.com/understanding-encoder-decoder-sequence-to-sequence-model-679e04af4346
Input
MAGIC
Motivating Example: Sequence Captioning
Example credit: https://towardsdatascience.com/understanding-encoder-decoder-sequence-to-sequence-model-679e04af4346
Input
MAGIC
Output
MAGIC
Encoder-Decoder Models
Encoder
x
Encoder
x z
Encoder
x z
Decoder
Encoder
x z
Decoder
y
Figure credit: https://stackabuse.com/autoencoders-for-image-reconstruction-in-python-and-keras/
Recall: Auto-Encoders
RNN encoder
x1 x2 xT-1 xT …
where is the library?
http://www.cs.cmu.edu/~mgormley/courses/10418/ Slide derived from Matt Gormley’s:
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
http://www.cs.cmu.edu/~mgormley/courses/10418/ Slide derived from Matt Gormley’s:
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
http://www.cs.cmu.edu/~mgormley/courses/10418/ Slide derived from Matt Gormley’s:
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
h1 h2 hT-1 hT …
http://www.cs.cmu.edu/~mgormley/courses/10418/ Slide derived from Matt Gormley’s:
Encoder
RNN refresher
Credit: Christopher Olah; https://colah.github.io/posts/2015-08-Understanding-LSTMs/
RNN refresher
Credit: Christopher Olah; https://colah.github.io/posts/2015-08-Understanding-LSTMs/
ht = fθ(xt, ht−1)
<latexit sha1_base64="ykFJ5c1d3j03cnvq6pmoTguSiIM=">ACXicbVDLSsNAFJ3UV62vqEs3g0WoCWpgm6EohuXFewD2hAm0k7dPJg5kYsIVs3/obF4q49Q/c+TdO0y60euDC4Zx7ufceLxZcgWV9GYWFxaXleJqaW19Y3PL3N5pqSiRlDVpJCLZ8YhigoesCRwE68SkcATrO2NriZ+45JxaPwFsYxcwIyCLnPKQEtuSYeuilk+AL7btqDIQOSVe5dOMr1Yzs7dM2yVbVy4L/EnpEymqHhmp+9fkSTgIVABVGqa1sxOCmRwKlgWamXKBYTOiID1tU0JAFTp/kuEDrfSxH0ldIeBc/TmRkCpceDpzoDAUM17E/E/r5uAf+6kPIwTYCGdLvITgSHCk1hwn0tGQYw1IVRyfSumQyIJBR1eSYdgz7/8l7RqVfukWrs5LdcvZ3EU0R7aRxVkozNUR9eogZqIogf0hF7Qq/FoPBtvxvu0tWDMZnbRLxgf3w+gmUc=</latexit>RNN refresher
Credit: Christopher Olah; https://colah.github.io/posts/2015-08-Understanding-LSTMs/
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
h1 h2 hT-1 hT …
http://www.cs.cmu.edu/~mgormley/courses/10418/ Slide derived from Matt Gormley’s:
y1 y2 yT-1 yT …
donde esta la bibliotheque?
Encoder
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
h1 h2 hT-1 hT …
RNN
Encoder
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
h1 h2 hT-1 hT …
RNN
START
Encoder Decoder
x1 x2 xT-1 xT …
where is the library?
RNN RNN RNN RNN
h1 h2 hT-1 hT …
RNN
Encoder
RNN RNN RNN
Decoder
y1 y2 yT-1 yT …
donde esta la bibliotheque? … START