Last active
January 22, 2021 02:23
-
-
Save hewumars/6889eaf6e8b279b930eddf1e606f8ace to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
torch.mm() | |
torch.bmm() batch-matrix-matrix两个3-dims矩阵相乘 | |
torch.matmul() | |
weights.reshape() | |
weights.resize_() | |
weights.view() | |
weights.from_numpy(numpy array) | |
tensor.numpy() | |
torch.detach()返回一个新的从当前图中分离出来的Variable,该Variable永远不需要梯度 | |
pytorch均值方差(bgr*255-mean)/std => svn工程 bgr*vStd - vMean 用numpy转换vMean = np.array([mean_b,mean_g,mean_r])/np.array([std_b,std_g,std_r]) vStd = 1/(255*np.array([std_b,std_g,std_r])) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment