From ec849a9503169fee0372ab29fcab5747e04294ab Mon Sep 17 00:00:00 2001 From: George Date: Wed, 30 Oct 2024 20:37:01 +0000 Subject: [PATCH] add version to quant config --- src/compressed_tensors/quantization/quant_config.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/compressed_tensors/quantization/quant_config.py b/src/compressed_tensors/quantization/quant_config.py index 04c8deb7..59c6e3f7 100644 --- a/src/compressed_tensors/quantization/quant_config.py +++ b/src/compressed_tensors/quantization/quant_config.py @@ -132,9 +132,10 @@ class QuantizationConfig(BaseModel): `k_proj` and `v_proj` in their names. If this is not the case and kv_cache_scheme != None, the quantization of kv cache will fail :global_compression_ratio: optional informational config to report the model - compression ratio acheived by the quantization config + compression ratio acheived by the quantization config :ignore: optional list of layers to ignore from config_groups. Layers in this list - are not quantized even if they match up with a target in config_groups + are not quantized even if they match up with a target in config_groups + :version param: version of the compressors used to optimize the given model """ config_groups: Dict[str, Union[QuantizationScheme, List[str]]] @@ -144,6 +145,7 @@ class QuantizationConfig(BaseModel): quantization_status: QuantizationStatus = QuantizationStatus.INITIALIZED global_compression_ratio: Optional[float] = None ignore: Optional[List[str]] = Field(default_factory=list) + version: str = "0.7.1" def model_post_init(self, __context): """