numpyで行列のmultiplicationをしたいのですがエラーが出ます。どういうことですか?
import numpy as np matrix_A = np.arange(1,9).reshape(2,4) matrix_B = np.arange(2,10).reshape(2,4) matrix_multiplication = np.dot(matrix_A, matrix_B)
ValueError Traceback (most recent call last)
<ipython-input-18-d23d99a3861f> in <module>
----> 2 matrix_multiplication = np.dot(matrix_A, matrix_B)
<array_function internals> in dot(*args, **kwargs)
ValueError: shapes (2,4) and (2,4) not aligned: 4 (dim 1) != 2 (dim 0)