ao icon indicating copy to clipboard operation
ao copied to clipboard

Change torchao quantization types from int to size_t and preface vars with "preferred_"

Open keyan opened this issue 1 year ago • 3 comments

Summary:

  1. Change the types of activation_data_alignment and weight_data_alignment from int to size_t.
  2. Change the return types of activation_data_size_fn_type and weight_data_size_fn_type from int to size_t.
  3. Rename activation_data_alignment to preferred_activation_data_alignment.
  4. Rename weight_data_alignment to preferred_weight_data_alignment

Differential Revision: D63873383

keyan avatar Oct 08 '24 22:10 keyan

:link: Helpful Links

:test_tube: See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/ao/1041

Note: Links to docs will display an error until the docs builds have been completed.

This comment was automatically generated by Dr. CI and updates every 15 minutes.

pytorch-bot[bot] avatar Oct 08 '24 22:10 pytorch-bot[bot]

This pull request was exported from Phabricator. Differential Revision: D63873383

facebook-github-bot avatar Oct 08 '24 22:10 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D63873383

facebook-github-bot avatar Oct 09 '24 00:10 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D63873383

facebook-github-bot avatar Oct 09 '24 20:10 facebook-github-bot

Ready for another look @metascroy, thanks!

keyan avatar Oct 09 '24 20:10 keyan

Ready for another look @metascroy, thanks!

Changes look good! Did you rerun the tests after making them?

metascroy avatar Oct 10 '24 00:10 metascroy

Changes look good! Did you rerun the tests after making them?

Yes, everything compiled/passed when running:

sh torchao/experimental/ops/benchmarks/build_and_run_benchmarks.sh
sh torchao/experimental/ops/linear_8bit_act_xbit_weight/examples/build_and_run_examples.sh stateful_class_wrapper
sh torchao/experimental/ops/linear_8bit_act_xbit_weight/examples/build_and_run_examples.sh separate_function_wrappers
sh torchao/experimental/build_torchao_ops.sh aten

keyan avatar Oct 10 '24 00:10 keyan