power(_:_:name:)
Returns the elementwise result of raising the first tensor to the power of the second tensor.
Declaration
func power(_ primaryTensor: MPSGraphTensor, _ secondaryTensor: MPSGraphTensor, name: String?) -> MPSGraphTensorParameters
- primaryTensor:
The LHS tensor of the binary Op.
- secondaryTensor:
The RHS tensor of the binary Op.
- name:
An optional string which serves as an identifier for the operation.
Return Value
A valid MPSGraphTensor object containing the elementwise result of the applied operation.
Discussion
This operation creates a power operation and returns the result tensor. It supports broadcasting as well.
resultTensor = pow(primaryTensor, secondaryTensor)