Ask Your Question
4

What does the ValueError with the message "matmul: Input operand 1 has a mismatch in its core dimension 0, with gufunc signature (n?,k),(k,m?)->(n?,m?)" mean when the size is 9 instead of 10?

asked 2023-07-16 02:43:10 +0000

nofretete gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2023-07-16 03:13:01 +0000

woof gravatar image

The ValueError with the message "matmul: Input operand 1 has a mismatch in its core dimension 0, with gufunc signature (n?,k),(k,m?)->(n?,m?)" means that the matrix multiplication operation (matmul) is being performed on two matrices where the size of the first matrix's first dimension does not match the size of the second matrix's second dimension.

When the size is 9 instead of 10, it means that one of the matrices has 9 rows or columns instead of 10. This results in a dimension mismatch error because for matrix multiplication, the number of columns in the first matrix needs to match the number of rows in the second matrix. In this case, the operation cannot be performed because one of the matrices does not have the required number of rows or columns.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2023-07-16 02:43:10 +0000

Seen: 7 times

Last updated: Jul 16 '23