diff --git a/tests/llmcompressor/transformers/obcq/test_consecutive_runs.py b/tests/llmcompressor/transformers/obcq/test_consecutive_runs.py index f70e7769fa..16c9003bed 100644 --- a/tests/llmcompressor/transformers/obcq/test_consecutive_runs.py +++ b/tests/llmcompressor/transformers/obcq/test_consecutive_runs.py @@ -8,6 +8,7 @@ from transformers import AutoModelForCausalLM from transformers.utils.quantization_config import CompressedTensorsConfig +from llmcompressor.transformers.utils import is_model_ct_quantized_from_path from llmcompressor.transformers.utils.helpers import infer_recipe_from_model_path from tests.testing_utils import parse_params, requires_gpu @@ -137,10 +138,14 @@ class TestConsecutiveRunsGPU(TestConsecutiveRuns): def setUp(self): from transformers import AutoModelForCausalLM + self.assertFalse( + is_model_ct_quantized_from_path(self.model), + "The provided model is quantized. Please use a dense model.", + ) + self.model = AutoModelForCausalLM.from_pretrained( self.model, device_map=self.device, - quantization_config=self.quantization_config, ) self.output = "./oneshot_output"