Templates
template rewriteTensor_AddMultiply{ C + `*`(A, B) }[T](A, B, C: Tensor[T]): auto
-
Fuse C + A * B into a single operation.
Operation fusion leverage the Nim compiler and should not be called explicitly.
Source Edit template rewriteTensor_MultiplyAdd{ `*`(A, B) + C }[T](A, B, C: Tensor[T]): auto
-
Fuse A*B + C into a single operation.
Operation fusion leverage the Nim compiler and should not be called explicitly.
Source Edit template rewriteTensor_MultiplyAdd_inplace{ C += `*`(A, B) }[T](A, B: Tensor[T]; C: var Tensor[T])
-
Fuse C+=A*B into a single operation.
Operation fusion leverage the Nim compiler and should not be called explicitly.
Source Edit template rewriteToTensorReshape{ reshape(toTensor(oa, dummy_bugfix), shape) }(oa: openArray; shape: varargs[int]; dummy_bugfix: static[int]): auto
-
Fuse sequence.toTensor.reshape(new_shape) into a single operation.
Operation fusion leverage the Nim compiler and should not be called explicitly.
Source Edit