Transpose
Say it: "A transpose"
What it means
Swap rows and columns: . An matrix becomes . Also written or .
Example
Rows become columns.
In code
import numpy as np A = np.array([[1, 2, 3], [4, 5, 6]]) print(A.T)
Output
[[1 4] [2 5] [3 6]]
Where it appears in machine learning
is the dot product; attention computes .
Related symbols
Learn it properly in the free lesson Matrices, with practice questions that check your answers.