ReduceLogSumExp - 13 vs 18

Next section compares an older to a newer version of the same operator after both definition are converted into markdown text. Green means an addition to the newer version, red means a deletion. Anything else is unchanged.

ReduceLogSumExp13 → ReduceLogSumExp18 RENAMED
@@ -1 +1 @@
1
1
  Computes the log sum exponent of the input tensor's elements along the provided axes. The resulting
2
2
  tensor has the same rank as the input if keepdims equals 1. If keepdims equals 0, then
3
3
  the resulting tensor has the reduced dimension pruned. Input tensors of rank zero are
4
4
  valid. Reduction over an empty set of values yields minus infinity (if supported by the datatype) or undefined otherwise.
5
5
  The above behavior is similar to numpy, with the exception that numpy defaults keepdims
6
6
  to False instead of True.
7
+ #### Function Body
8
+
9
+ The function definition for this operator.
10
+
11
+
12
+ <
13
+ domain: "",
14
+ opset_import: ["" : 18]
15
+ >
16
+ ReduceLogSumExp <noop_with_empty_axes,keepdims>(data, axes) => (reduced)
17
+ {
18
+ data_double = Cast <to: int = 11> (data)
19
+ data_exp = Exp (data_double)
20
+ reduced_sum = ReduceSum <keepdims: int = @keepdims> (data_exp, axes)
21
+ reduced_double = Log (reduced_sum)
22
+ reduced = CastLike (reduced_double, data)
23
+ }
24
+
25
+
7
26
  ### Attributes
8
-
9
- * **axes - INTS** :
10
-
11
- A list of integers, along which to reduce. The default is to reduce over all the dimensions of the input tensor. Accepted range is [-r, r-1] where r = rank(data).
12
27
  * **keepdims - INT** (default is '1'):
13
28
  Keep the reduced dimension or not, default 1 means keep reduced dimension.
29
+ * **noop_with_empty_axes - INT** (default is '0'):
30
+
31
+ Defines behavior if 'axes' is empty. Default behavior with 'false' is to reduce all axes. When axes is empty and this attribute is set to true, input tensor will not be reduced,and the output tensor would be equivalent to input tensor.
32
+
14
33
  ### Inputs
34
+
35
+ Between 1 and 2 inputs.
15
36
  - **data** (heterogeneous) - **T**:
16
37
  An input tensor.
38
+ - **axes** (optional, heterogeneous) - **tensor(int64)**:
39
+
40
+ Optional input list of integers, along which to reduce. The default is to reduce over all the dimensions of the input tensor if 'noop_with_empty_axes' is false, else act as an Identity op when 'noop_with_empty_axes' is true. Accepted range is [-r, r-1] where r = rank(data).
17
41
  ### Outputs
18
42
  - **reduced** (heterogeneous) - **T**:
19
43
  Reduced output tensor.
20
44
  ### Type Constraints
21
45
  * **T** in ( tensor(bfloat16), tensor(double), tensor(float), tensor(float16), tensor(int32), tensor(int64), tensor(uint32), tensor(uint64) ):
22
46
  Constrain input and output types to numeric tensors.