Pointwise and Reduction
Pointwise
The pointwise operation performs an elementwise operation between two tensors. The operation used is controlled by pointwise mode cudnn_frontend::PointwiseMode_t.
C++ API
The pointwise mode dictates the API among the choices above. Refer to the documentation of cudnn_frontend::PointwiseMode_t for details.
Pointwise attributes is a lightweight structure with setters:
Python API
- add
- a
- b
- compute_data_type
- name
- bias
- input
- bias
- compute_data_type
- name
- rsqrt
- input
- compute_data_type
- name
- sub
- a
- b
- compute_data_type
- name
- mul
- a
- b
- compute_data_type
- name
- scale
- input
- scale
- compute_data_type
- name
- relu
- input
- compute_data_type
- name
- gelu
- input
- compute_data_type
- name
- elu
- input
- compute_data_type
- name
- cmp_gt
- input
- comparison
- compute_data_type
- name
Reduction
The reduction operation reduces an input tensor using an operation controlled by cudnn_frontend::ReductionMode_t. The dimensions in input tensors to reduce are deduced using output tensor dimensions.
C++ API
Reduction attributes is a lightweight structure with setters: