Repository navigation
Tags: protonu/ao
Tags
Refactor MXTensor: align the swizzle execution with the configured sw… …izzle setting
Refactor MXTensor: replace is_swizzled_scales bool with SwizzleType c… …lass hierarchy
Refactor MXTensor: Use SwizzleType class for device-agnostic scale l… …ayout dispatch
Add device-specific tensor registration pattern and XPU MX example
Update skip reason for test_bmm_operation_with_observer Co-authored-by: Cursor <cursoragent@cursor.com>
Address review: use torch.accelerator.current_accelerator() Per review feedback, replace the torchao.utils.get_current_accelerator_device() helper with the upstream torch.accelerator.current_accelerator() API, which is the direction tracked in pytorch#2917 / pytorch#4384. Note the suggested spelling in the review comment, torch.accelerator.get_current_accelerator(), does not exist; the actual API is torch.accelerator.current_accelerator(). This also avoids the helper's assert torch.accelerator.is_available(), which would raise on CPU-only runners; current_accelerator() returns None there and the comparison simply evaluates to False.
Address review: use torch.accelerator.current_accelerator() Per review feedback, replace the torchao.utils.get_current_accelerator_device() helper with the upstream torch.accelerator.current_accelerator() API, which is the direction tracked in pytorch#2917 / pytorch#4384. Note the suggested spelling in the review comment, torch.accelerator.get_current_accelerator(), does not exist; the actual API is torch.accelerator.current_accelerator().
Address review: use torch.accelerator.current_accelerator() Per review feedback, replace the torchao.utils.get_current_accelerator_device() helper with the upstream torch.accelerator.current_accelerator() API, which is the direction tracked in pytorch#2917 / pytorch#4384. Note the suggested spelling in the review comment, torch.accelerator.get_current_accelerator(), does not exist; the actual API is torch.accelerator.current_accelerator(). Scoped to the call site added by this PR; the pre-existing ones in this file are left to the file-wide migration.
Address review: use torch.accelerator.current_accelerator() Per review feedback, replace the torchao.utils.get_current_accelerator_device() helper with the upstream torch.accelerator.current_accelerator() API, which is the direction tracked in pytorch#2917 / pytorch#4384. Note the suggested spelling in the review comment, torch.accelerator.get_current_accelerator(), does not exist; the actual API is torch.accelerator.current_accelerator(). This also drops the torchao.utils import that the previous commit added, since it would otherwise be unused (ruff F401).
Address review: use torch.accelerator.current_accelerator() Per review feedback, replace the torchao.utils.get_current_accelerator_device() helper with the upstream torch.accelerator.current_accelerator() API, which is the direction tracked in pytorch#2917 / pytorch#4384. Note the suggested spelling in the review comment, torch.accelerator.get_current_accelerator(), does not exist; the actual API is torch.accelerator.current_accelerator(). The torchao.utils import of the helper is dropped along with it, since it would otherwise be unused (ruff F401).
PreviousNext