NonZero - 9 vs 13#
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.
- NonZero9 → NonZero13 +0 -1
NonZero9 → NonZero13
RENAMED
@@ -1 +1 @@
|
|
1
1
|
Returns the indices of the elements that are non-zero
|
2
2
|
(in row-major order - by dimension).
|
3
3
|
NonZero behaves similar to numpy.nonzero:
|
4
4
|
https://docs.scipy.org/doc/numpy/reference/generated/numpy.nonzero.html,
|
5
5
|
but for scalar input, NonZero produces output shape (0, N) instead of (1, N), which is different from Numpy's behavior.
|
6
6
|
**Inputs**
|
7
7
|
* **X** (heterogeneous) - **T**:
|
8
8
|
input
|
9
9
|
**Outputs**
|
10
10
|
* **Y** (heterogeneous) - **tensor(int64)**:
|
11
11
|
output
|
12
12
|
**Type Constraints**
|
13
13
|
* **T** in (
|
14
|
-
tensor(bfloat16),
|
15
14
|
tensor(bool),
|
16
15
|
tensor(complex128),
|
17
16
|
tensor(complex64),
|
18
17
|
tensor(double),
|
19
18
|
tensor(float),
|
20
19
|
tensor(float16),
|
21
20
|
tensor(int16),
|
22
21
|
tensor(int32),
|
23
22
|
tensor(int64),
|
24
23
|
tensor(int8),
|
25
24
|
tensor(string),
|
26
25
|
tensor(uint16),
|
27
26
|
tensor(uint32),
|
28
27
|
tensor(uint64),
|
29
28
|
tensor(uint8)
|
30
29
|
):
|
31
30
|
Constrain to all tensor types.
|