np.matmul([[1,2],[3,4]], [[5,6],[7,8]]) # [[19,22], [43,50]] # A @ B last 2 axis numpy.matmul — NumPy v2.1 ManualA location into which the result is stored. If provided, it must have a shape that matches the signature (n,k),(k,m)->(n,m). If not provided or None, a freshly-allocated array is returned.https://numpy.org/doc/stable/reference/generated/numpy.matmul.html