Skip to content

Commit a6bc3fa

Browse files
authored
Merge branch 'main' into torch-compile-observers
2 parents 47a0b12 + a2433a9 commit a6bc3fa

File tree

176 files changed

+2642
-3787
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

176 files changed

+2642
-3787
lines changed

.MAINTAINERS

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/mergify.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,43 @@
1+
queue_rules:
2+
- name: default
3+
merge_method: merge
4+
commit_message_template: |
5+
{{ title }} (#{{ number }})
6+
7+
{{ body }}
8+
9+
Signed-off-by: Mergify <noreply@mergify.com>
10+
queue_conditions:
11+
- check-success=DCO
12+
- check-success=quality-check
13+
- check-success=transformers-tests
14+
- check-success=base-tests (3.10)
15+
- check-success=base-tests (3.13)
16+
- check-success=pytorch-tests (3.10)
17+
- check-success=pytorch-tests (3.13)
18+
- check-success=markdown-link-check
19+
120
pull_request_rules:
21+
- name: Automatically merge when ready
22+
conditions:
23+
- base=main
24+
- label=ready
25+
- "#approved-reviews-by>=2"
26+
- check-success=DCO
27+
- check-success=quality-check
28+
- check-success=transformers-tests
29+
- check-success=base-tests (3.10)
30+
- check-success=base-tests (3.13)
31+
- check-success=pytorch-tests (3.10)
32+
- check-success=pytorch-tests (3.13)
33+
- check-success=markdown-link-check
34+
- check-success=ready-label-check
35+
- -conflict
36+
- -draft
37+
actions:
38+
queue:
39+
name: default
40+
241
- name: label-documentation
342
description: Automatically apply documentation label
443
conditions:

README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,12 @@ Big updates have landed in LLM Compressor! To get a more in-depth look, check ou
3737

3838
Some of the exciting new features include:
3939

40-
* **Batched Calibration Support**: LLM Compressor now supports calibration with batch sizes > 1. A new [`batch_size`](src/llmcompressor/args/dataset_arguments.py#L70) argument has been added to the `dataset_arguments` enabling the option to improve quantization speed. Default `batch_size` is currently set to 1
40+
* **Updated offloading and model loading support**: Loading transformers models that are offloaded to disk and/or offloaded across distributed process ranks is now supported. Disk offloading allows users to load and compress very large models which normally would not fit in CPU memory. Offloading functionality is no longer supported through accelerate but through model loading utilities added to compressed-tensors. For a full summary of updated loading and offloading functionality, for both single-process and distributed flows, see the [Big Models and Distributed Support guide](docs/guides/big_models_and_distributed/model_loading.md).
41+
* **Distributed GPTQ Support**: GPTQ now supports Distributed Data Parallel (DDP) functionality to significantly improve calibration runtime. An example using DDP with GPTQ can be found [here](examples/quantization_w4a16/llama3_ddp_example.py).
42+
* **Updated FP4 Microscale Support**: GPTQ now supports FP4 quantization schemes, including both [MXFP4](examples/quantization_w4a16_fp4/mxfp4/llama3_example.py) and [NVFP4](examples/quantization_w4a4_fp4/llama3_gptq_example.py). MXFP4 support has also been improved with updated weight scale generation. Models with weight-only quantization in the MXFP4 format can now run in vLLM as of vLLM v0.14.0. MXFP4 models with activation quantization are not yet supported in vLLM for compressed-tensors models
4143
* **New Model-Free PTQ Pathway**: A new model-free PTQ pathway has been added to LLM Compressor, called [`model_free_ptq`](src/llmcompressor/entrypoints/model_free/__init__.py#L36). This pathway allows you to quantize your model without the requirement of Hugging Face model definition and is especially useful in cases where `oneshot` may fail. This pathway is currently supported for data-free pathways only i.e FP8 quantization and was leveraged to quantize the [Mistral Large 3 model](https://huggingface.co/mistralai/Mistral-Large-3-675B-Instruct-2512). Additional [examples](examples/model_free_ptq) have been added illustrating how LLM Compressor can be used for Kimi K2
4244
* **Extended KV Cache and Attention Quantization Support**: LLM Compressor now supports attention quantization. KV Cache quantization, which previously only supported per-tensor scales, has been extended to support any quantization scheme including a new `per-head` quantization scheme. Support for these checkpoints is on-going in vLLM and scripts to get started have been added to the [experimental folder](experimental/attention)
43-
* **Generalized AWQ Support**: The AWQModifier has been updated to support quantization schemes beyond W4A16 (e.g W4AFp8). In particular, AWQ no longer constrains that the quantization config needs to have the same settings for `group_size`, `symmetric`, and `num_bits` for each config_group
44-
* **AutoRound Quantization Support**: Added [`AutoRoundModifier`](examples/autoround) for quantization using [AutoRound](https://aclanthology.org/2024.findings-emnlp.662.pdf), an advanced post-training algorithm that optimizes rounding and clipping ranges through sign-gradient descent. This approach combines the efficiency of post-training quantization with the adaptability of parameter tuning, delivering robust compression for large language models while maintaining strong performance
45-
* **Experimental MXFP4 Support**: Models can now be quantized using an [`MXFP4`](https://github.com/vllm-project/compressed-tensors/blob/main/src/compressed_tensors/quantization/quant_scheme.py#L208) pre-set scheme. Examples can be found under the [experimental folder](experimental/mxfp4/llama3_mxfp4.py). This pathway is still experimental as support and validation with vLLM is still a WIP.
46-
* **R3 Transform Support**: LLM Compressor now supports applying transforms to attention in the style of SpinQuant's R3 rotation. Note: this feature is currently not yet supported in vLLM. An example applying R3 can be found in the [experimental folder](experimental/attention/llama3_attention_r3_nvfp4.py)
45+
4746

4847
### Supported Formats
4948
* Activation Quantization: W8A8 (int8 and fp8)

docs/.nav.yml

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
nav:
22
- Home: index.md
3-
- Why use LLM Compressor?: getting-started/why-llmcompressor.md
4-
- Choosing the right compression scheme: getting-started/choosing-scheme.md
5-
- Choosing the right compression algorithm: getting-started/choosing-algo.md
3+
- Why use LLM Compressor?: steps/why-llmcompressor.md
4+
- Compresssing your model, step-by-step:
5+
- Choosing your model: steps/choosing-model.md
6+
- Choosing the right compression scheme: steps/choosing-scheme.md
7+
- Choosing the right compression algorithm: steps/choosing-algo.md
8+
- Choosing a dataset: steps/choosing-dataset.md
9+
- Compressing your model: steps/compress.md
10+
- Deploying with vLLM: steps/deploy.md
611
- Getting started:
712
- getting-started/index.md
813
- Installing LLM Compressor: getting-started/install.md
9-
- Compressing your Model: getting-started/compress.md
10-
- Deploying with vLLM: getting-started/deploy.md
11-
- FAQ: getting-started/faq.md
1214
- Key Models:
1315
- key-models/index.md
1416
- Llama 4:
@@ -24,14 +26,25 @@ nav:
2426
- key-models/mistral-large-3/index.md
2527
- FP8 Example: key-models/mistral-large-3/fp8-example.md
2628
- Guides:
29+
- Big Models and Distributed Support:
30+
- Model Loading: guides/big_models_and_distributed/model_loading.md
31+
- Sequential Onloading: guides/big_models_and_distributed/sequential_onloading.md
32+
- Distributed Oneshot: guides/big_models_and_distributed/distributed_oneshot.md
2733
- Compression Schemes: guides/compression_schemes.md
2834
- Saving a Model: guides/saving_a_model.md
29-
- Observers: observers.md
35+
- Observers: guides/observers.md
36+
- Memory Requirements: guides/memory.md
37+
- Runtime Performance: guides/runtime.md
3038
- Examples:
31-
- examples/index.md
39+
- examples/README.md
3240
- examples/*
41+
- Experimental:
42+
- experimental/README.md
43+
- experimental/*
3344
- Developer:
3445
- developer/index.md
3546
- developer/*
3647
- API Reference:
3748
- api/*
49+
- FAQ:
50+
- faq/faq.md

docs/api/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ oneshot(
1919
```
2020

2121
For advanced usage, you can configure individual modifiers and apply them directly to models.
22-
See the [Examples](../examples/index.md) section for detailed usage patterns.
22+
See the [Examples](https://github.com/vllm-project/llm-compressor/tree/main/examples) section for detailed usage patterns.

docs/assets/model_graph.jpg

463 KB
Loading

docs/assets/seq_targets.jpg

116 KB
Loading
153 KB
Loading
138 KB
Loading

docs/examples/index.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)