numpy 三维数组相乘

 

 

https://stackoverflow.com/questions/64952700/multiplying-two-3d-pytorch-tensors-iteratively

https://blog.csdn.net/Mluoo/article/details/129873458

 

numpy 三维数组相乘

import numpy as np
a=np.zeros((2,2,2))
a[:,:,0]=([[3,6],[5,8]])
a[:,:,1]=([[2,5],[7,2]])
b=np.zeros((2,2,2))
b[:,:,0]=([[3,2],[9,6]])
b[:,:,1]=([[7,8],[1,0]])
c=a*b

 

 

pytorch 三维张量相乘

 

posted @ 2023-10-07 11:18  emanlee  阅读(54)  评论(0编辑  收藏  举报