Skip to content

[tests] tests for compilation + quantization (bnb) - #11672

Merged
sayakpaul merged 12 commits into
mainfrom
quant-compile-tests
Jun 11, 2025
Merged

[tests] tests for compilation + quantization (bnb)#11672
sayakpaul merged 12 commits into
mainfrom
quant-compile-tests

Conversation

@sayakpaul

@sayakpaul sayakpaul commented Jun 6, 2025

Copy link
Copy Markdown
Member

What does this PR do?

Adds tests for

  • quant + compilation
  • quant + compilation + model CPU offloading
  • quant + compilation + group offloading

Does this for bitsandbytes for now.

@sayakpaul sayakpaul added quantization performance Anything related to performance improvements, profiling and benchmarking torch.compile labels Jun 6, 2025
Comment thread tests/quantization/bnb/test_4bit.py Outdated
@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@sayakpaul
sayakpaul requested a review from matthewdouglas June 6, 2025 09:36
Comment thread tests/quantization/bnb/test_4bit.py
@sayakpaul sayakpaul changed the title [wip][tests] start adding tests for compilation + quantization [tests] tests for compilation + quantization (bnb) Jun 7, 2025
@sayakpaul
sayakpaul marked this pull request as ready for review June 7, 2025 04:45
@sayakpaul
sayakpaul requested review from DN6 and matthewdouglas June 7, 2025 04:45
@sayakpaul

Copy link
Copy Markdown
Member Author

@DN6 LMK what you think of the test suite. The combinations target consumer GPU where using quantization is beneficial (cc: @asomoza). Would you be able to add this for GGUF, too?

Also cc: @stevhliu I think we should try to document these combos of optims in an easy manner now that we know they work (I can help get latency and memory numbers).

Comment thread tests/quantization/test_torch_compile_utils.py Outdated
@sayakpaul

Copy link
Copy Markdown
Member Author

Also cc @a-r-r-o-w see if any of these tests can be propagated to TorchAO as well. LMK if there's anything I can help with.

@sayakpaul
sayakpaul merged commit b6f7933 into main Jun 11, 2025
@sayakpaul
sayakpaul deleted the quant-compile-tests branch June 11, 2025 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

performance Anything related to performance improvements, profiling and benchmarking quantization torch.compile

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants