In Python, the @ operator relays to the __matmul__ property of an element. This comes in handy when implementing a method that stays agnostic of the actual backend. For example
def inner(x, y):
return x @ y
# same:
# return x.__matmul__(y)
implements an inner product, for x, y being numpy arrays or any other fancy array class.
Is there a similar such API for the outer product, too?