-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#16679: K min values support for TopK #16917
Conversation
@atatuzunerTT : since this PR is editing files |
c835a91
to
2f9e962
Compare
|
lgtm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only see changes for WH and BH.
What will be the behaviour for GS, does the functionality already exist?
GS doesn't have support for the topk kernel |
9f3fe94
to
3664d1b
Compare
b833a22
to
cffa3e4
Compare
### Ticket [Link to Github Issue](#16679) ### Problem description TopK currently supports max sorting, where K max values are returned. We need to add necessary changes to LLKs to support returning the K min values. ### What's changed LLKs were updated to pass down a flag specifying which behavior (largest or smallest k values) is expected. Ckernel updated to place min values into register instead of max values when flag is set, returning k min values as a result. ### Checklist - [x] [Post commit CI passes](https://github.com/tenstorrent/tt-metal/actions/runs/12932508914) - [x] [Blackhole Post commit](https://github.com/tenstorrent/tt-metal/actions/runs/12932523648) (if applicable) - [ ] Model regression CI testing passes (if applicable) - [ ] Device performance regression CI testing passes (if applicable) - [ ] **(For models and ops writers)** Full [new models](https://github.com/tenstorrent/tt-metal/actions/workflows/full-new-models-suite.yaml) tests passes - [ ] New/Existing tests provide coverage for changes
### Ticket [Link to Github Issue](#16679) ### Problem description TopK currently supports max sorting, where K max values are returned. We need to add necessary changes to LLKs to support returning the K min values. ### What's changed LLKs were updated to pass down a flag specifying which behavior (largest or smallest k values) is expected. Ckernel updated to place min values into register instead of max values when flag is set, returning k min values as a result. ### Checklist - [x] [Post commit CI passes](https://github.com/tenstorrent/tt-metal/actions/runs/12932508914) - [x] [Blackhole Post commit](https://github.com/tenstorrent/tt-metal/actions/runs/12932523648) (if applicable) - [ ] Model regression CI testing passes (if applicable) - [ ] Device performance regression CI testing passes (if applicable) - [ ] **(For models and ops writers)** Full [new models](https://github.com/tenstorrent/tt-metal/actions/workflows/full-new-models-suite.yaml) tests passes - [ ] New/Existing tests provide coverage for changes
Ticket
Link to Github Issue
Problem description
TopK currently supports max sorting, where K max values are returned. We need to add necessary changes to LLKs to support returning the K min values.
What's changed
LLKs were updated to pass down a flag specifying which behavior (largest or smallest k values) is expected. Ckernel updated to place min values into register instead of max values when flag is set, returning k min values as a result.
Checklist