当前位置:网站首页>Swintransformer network architecture

Swintransformer network architecture

2022-06-12 16:55:00 QT-Smile

SwinTransformer

1. original text :
 Insert picture description here
2.
 Insert picture description here
3.
 Insert picture description here
4.
For different versions of Swin Transformer Model , there C It's different
 Insert picture description here
5.
Conduct Linear Embedding after , Each channel is also Layer Norm
 Insert picture description here
6.
Both of these are implemented according to the convolution layer
 Insert picture description here
7.
Here are two Swin Transformer Blocks, But these two are usually used in pairs
 Insert picture description here
8.
The multi-layer perceptron here is Vision Transformer The author said , So I didn't talk about it in this video
 Insert picture description here
9.
This position , For classified networks , In fact, there is a network structure behind it , It's just not drawn here
 Insert picture description here
10.
after Patch Merging Then the length and width of the characteristic matrix will be halved , The number of channels will be doubled
 Insert picture description here
11.
11.
 Insert picture description here  Insert picture description here
12.
MSA Namely transformer The long attention mechanism in ,MSA That is, every pixel of the characteristic matrix will calculate its Q,K,V, And every pixel will also go with other pixels K Multiply , Calculate the relevant weights , Finally multiply by the relevant V, Finally hungry to the final result .
 Insert picture description here
W-MSA Is to use for each small characteristic matrix MSA, The author did this to reduce the amount of computation .
 Insert picture description here

W-MSA shortcoming : There is no information exchange between windows , So I can put MDTA and W-MSA Make two branches , Calculate details and global information respectively , Or use convolution layers and W-MSA Make two branches , Convolution layer calculates global information ,W-MSA Calculate local information .
 Insert picture description here 14.
 Insert picture description here
15.
In order to solve W-MSA The disadvantage of not being able to communicate between different windows , Created SW-MSA
 Insert picture description here
 Insert picture description here
16.

 Insert picture description here
Put the matrix above , First move two pixels up , Then move two pixels to the left to get the following characteristic matrix
 Insert picture description here
17.
 Insert picture description here
 Insert picture description here
 Insert picture description here  Insert picture description here
 Insert picture description here
 Insert picture description here

 Insert picture description here
 Insert picture description here
18.

 Insert picture description here
 Insert picture description here
 Insert picture description here
 Insert picture description here
 Insert picture description here
 Insert picture description here

 Insert picture description here

The final functions of the two structures are the same
 Insert picture description here
21.
With Swin-T give an example
 Insert picture description here
 Insert picture description here

 Insert picture description here

原网站

版权声明
本文为[QT-Smile]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/163/202206121634419240.html