全部文章

How Transformers Work

Transformers were developed to solve the problem of sequence transduction, or neural machine translation. That means any task that transforms an input sequence to an output sequence.

Recurrent Neural Networks (RNNs) and Convolutional Neural Networks (CNNs) have been used to deal with this problem because of their properties.

Recurrent Neural Networks

Recurrent Neural Networks have loops in them, allowing information to persist.

a

A Recurrent Neural Network can be thought of as multiple copies of the same network, A, each network passing a message to a successor.

recurrent neural networks are clearly related to sequences and lists.

Long-Short Term Memory (LSTM)

The problem with LSTMs

Attention

Convolutional Neural Networks

Transformers

Self-Attention

Self-Attention

Multihead attention

Positional Encoding

Overview

towardsdatascience.com How Transformers Work 阅读原文