Skip to content
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

rename splitk code to not mention float8, try 2 #529

Merged
merged 1 commit into from
Jul 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions test/dtypes/test_fp8.py → test/prototype/test_splitk.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from torchao.utils import TORCH_VERSION_AFTER_2_4

try:
from torchao.prototype.fp8 import gemm_split_k, to_float8
from torchao.prototype.splitk import gemm_split_k, to_float8
triton_available = True
except ImportError:
triton_available = False
Expand Down Expand Up @@ -38,7 +38,7 @@ def test_gemm_split_k(self):
x_fp8, x_inv_s = to_float8(x, dtype=qdtype)
w_fp8, w_inv_s = to_float8(w, dtype=qdtype)

y_torch, _ = torch._scaled_mm(x_fp8, w_fp8.t(), out_dtype=dtype, scale_a=x_inv_s, scale_b=w_inv_s)
y_torch = torch._scaled_mm(x_fp8, w_fp8.t(), out_dtype=dtype, scale_a=x_inv_s, scale_b=w_inv_s)
y_triton = gemm_split_k(x_fp8, w_fp8.t(), scale_a=x_inv_s.item(), scale_b=w_inv_s.item())
y_fp16 = torch.nn.functional.linear(x, w)

Expand Down
File renamed without changes.
Loading