-
Notifications
You must be signed in to change notification settings - Fork 17
fix: Fixes for paged fp8 attention with chunked prefill #191
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Antoni Viros i Martin <[email protected]>
Signed-off-by: Antoni Viros i Martin <[email protected]>
|
@ani300 by registering a custom We need to either suppress it or declare a kernel with a name distinct from the official Aten operation. |
|
what functionality do we need that is not provided by the conventional |
|
Scales that aren't per tensor, we can refactor it I guess. |
Signed-off-by: Antoni Viros i Martin <[email protected]>
|
Fixed the warning, now trying if it works with DPP before asking for merge |
|
@andrea-fasoli The code compiled successfully for CPU using DPP tests in AIU, so the fix works. |
andrea-fasoli
left a comment
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.
looks good to me
Description of the change
This PR ports the fixes to paged attention coming from chunked prefill implementations to the FP8 variant, and restores our custom CPU implementation for scaled_bmm, as the Pytorch CPU does not support per-sentence kv-scales, which we need for our current fp8 implementation.
Related issues or PRs
See https://ibm.enterprise.slack.com/archives/C04FKKQ11LH/p1762528936408799?thread_ts=1762528936.408799&cid=C04FKKQ11LH for details on the fix.
How to verify the PR
Running DPP (https://github.com/foundation-model-stack/aiu-fms-testing-utils/blob/main/aiu_fms_testing_utils/scripts/drive_paged_programs.py) like this:
produces the expected graph and results now.
Was the PR tested
Checklist for passing CI/CD:
git commit -signoffor equivalenttox -e fixtox -e linttox -e spellchecktox -e unitNote: CI/CD performs unit tests on multiple versions of Python from a fresh install. There may be differences with your local environment and the test environment.