8000 Update signatures · data-apis/array-api-comparison@f1babd5 · GitHub
[go: up one dir, main page]

Skip to content
Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f1babd5

Browse files
committed
Update signatures
1 parent 724bcc0 commit f1babd5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

signatures/searching/top_k.md

Lines changed: 3 additions & 3 deletions
< 8000 td data-grid-cell-id="diff-354c4c4c48e196ac64b631bdb215aa2bb3794f008bbebc65316efb6f4042d525-64-64-0" data-selected="false" role="gridcell" style="background-color:var(--bgColor-accent-muted, var(--color-accent-subtle));flex-grow:1" tabindex="-1" valign="top" class="focusable-grid-cell diff-hunk-cell left-side" colSpan="4">
@@ -65,15 +65,15 @@ jax.numpy.argpartition(a, kth, axis=-1) → ndarray
Original file line numberDiff line numberDiff line change
6565
## MXNet
6666

6767
```
68-
npx.topk(data, axis=-1, k=1, ret_typ='indices', is_ascend=False, dtype='float32') → ndarray | [ndarray, ndarray]
68+
npx.topk(data, axis=-1, k=1, ret_typ='indices', is_ascend=False, dtype='float32') → ndarray | tuple[ndarray, ndarray]
6969
```
7070

7171
**Note**: whether a single ndarray or a list of ndarrays is returned is determined by `ret_type`. Differs from NumPy et al in providing a default value for `k`.
7272

7373
## PyTorch
7474

7575
```
76-
torch.topk(input, k, dim=None, largest=True, sorted=True, *, out=None) → (Tensor, LongTensor)
76+
torch.topk(input, k, dim=None, largest=True, sorted=True, *, out=None) → tuple[Tensor, LongTensor]
7777
```
7878

7979
**Note**: returns a named tuple containing values and indices. Differs from NumPy et al for default `dim`.
@@ -82,7 +82,7 @@ torch.topk(input, k, dim=None, largest=True, sorted=True, *, out=None) → (Tens
8282

8383
```
8484
tf.math.top_k(input, k=1, sorted=True, index_type=tf.dtypes.int32, name=None
85-
) → (Tensor, Tensor)
85+
) → tuple[Tensor, Tensor]
8686
```
8787

8888
**Note**: returns a `(values, indices)` tuple. Only supports last axis.

0 commit comments

Comments
 (0)
0