Multiply each matrix in a list of matrices with a unique scalar found in a vector

后端 未结 0 420
情话喂你
情话喂你 2020-12-07 23:59

I have a numpy array list of matrices, i.e a "3d matrix" if that exists.

x = np.array([[1,2,3],[4,5,6],[7,8,9]])
print(x[:,:,None]*x[:,None,:])

[[[         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题