Math and algorithms
Miscellaneous math and algorithm code
Matrix functions
matrix_power
def matrix_power(
x:Tensor, p:float
)->Tensor:
Power of a matrix using Eigenspace Decomposition. Assuming decomposition of x exists.
Algorithms
gram_schmidt
def gram_schmidt(
X:Tensor
):
Perform Gram–Schmidt orthonormalization on the vectors given by the rows of matrix X.