Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Negates each element of InputTensor, storing the result into the corresponding element of OutputTensor.
f(x) = -x
This operator supports in-place execution, meaning that OutputTensor is permitted to alias InputTensor during binding.
Syntax
struct DML_ELEMENT_WISE_NEGATE_OPERATOR_DESC {
const DML_TENSOR_DESC *InputTensor;
const DML_TENSOR_DESC *OutputTensor;
};
Members
InputTensor
Type: const DML_TENSOR_DESC*
The input tensor to read from.
OutputTensor
Type: const DML_TENSOR_DESC*
The output tensor to write the results to.
Remarks
Availability
This operator was introduced in DML_FEATURE_LEVEL_5_0.
Tensor constraints
InputTensor and OutputTensor must have the same DataType, DimensionCount, and Sizes.
Tensor support
Tensor | Kind | Supported dimension counts | Supported data types |
---|---|---|---|
InputTensor | Input | 1 to 8 | FLOAT32, FLOAT16, INT64, INT32, INT16, INT8 |
OutputTensor | Output | 1 to 8 | FLOAT32, FLOAT16, INT64, INT32, INT16, INT8 |
Requirements
Requirement | Value |
---|---|
Header | directml.h |