Skip to content
This repository was archived by the owner on Jan 28, 2026. It is now read-only.

Support torch_fp8#13196

Merged
cyita merged 6 commits intointel:mainfrom
cyita:fp8-test
Jun 4, 2025
Merged

Support torch_fp8#13196
cyita merged 6 commits intointel:mainfrom
cyita:fp8-test

Conversation

@cyita
Copy link
Copy Markdown
Contributor

@cyita cyita commented May 29, 2025

Description

  • Add torch_fp8, torch_fp8_e5m2 and torch_fp8_e4m3
model = optimize_model(model, low_bit="torch_fp8", torch_dtype=dtype)
model = model.to("xpu")
output_fp8 = model.linear(input)

1. Why the change?

2. User API changes

3. Summary of the change

4. How to test?

  • N/A
  • Unit test: Please manually trigger the PR Validation here by inputting the PR number (e.g., 1234). And paste your action link here once it has been successfully finished.
  • Application test
  • Document test
  • ...

5. New dependencies

  • New Python dependencies
    - Dependency1
    - Dependency2
    - ...
  • New Java/Scala dependencies and their license
    - Dependency1 and license1
    - Dependency2 and license2
    - ...

Comment thread python/llm/src/ipex_llm/transformers/low_bit_linear.py
@cyita cyita requested review from rnwang04 and xiangyuT May 29, 2025 08:35
Comment thread python/llm/src/ipex_llm/transformers/low_bit_linear.py Outdated
Comment thread python/llm/src/ipex_llm/transformers/low_bit_linear.py Outdated
Copy link
Copy Markdown
Contributor

@rnwang04 rnwang04 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
There may need more restrictions for this new type, like only support Linux / only used for BMG / save & load etc. But these are not urgent, we can consider such issues later.

Copy link
Copy Markdown

@qiyuangong qiyuangong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cyita
Copy link
Copy Markdown
Contributor Author

cyita commented Jun 4, 2025

@cyita cyita merged commit e032156 into intel:main Jun 4, 2025
1 check passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants