Remove all traces of low_cpu_mem_usage (#38792)
* remove it from all py files * remove it from the doc * remove it from examples * style * remove traces of _fast_init * Update test_peft_integration.py * CIs
This commit is contained in:
@@ -328,7 +328,6 @@ class AwqFusedTest(unittest.TestCase):
|
||||
model = AutoModelForCausalLM.from_pretrained(
|
||||
self.model_name,
|
||||
quantization_config=quantization_config,
|
||||
low_cpu_mem_usage=True,
|
||||
revision=self.model_revision,
|
||||
).to(torch_device)
|
||||
|
||||
@@ -347,7 +346,6 @@ class AwqFusedTest(unittest.TestCase):
|
||||
model = AutoModelForCausalLM.from_pretrained(
|
||||
model_id,
|
||||
quantization_config=quantization_config,
|
||||
low_cpu_mem_usage=True,
|
||||
).to(torch_device)
|
||||
|
||||
# Check if model has been correctly fused
|
||||
@@ -370,7 +368,6 @@ class AwqFusedTest(unittest.TestCase):
|
||||
model = AutoModelForCausalLM.from_pretrained(
|
||||
self.model_name,
|
||||
quantization_config=quantization_config,
|
||||
low_cpu_mem_usage=True,
|
||||
revision=self.model_revision,
|
||||
).to(torch_device)
|
||||
|
||||
@@ -399,7 +396,6 @@ class AwqFusedTest(unittest.TestCase):
|
||||
model = AutoModelForCausalLM.from_pretrained(
|
||||
self.model_name,
|
||||
quantization_config=quantization_config,
|
||||
low_cpu_mem_usage=True,
|
||||
revision=self.model_revision,
|
||||
).to(torch_device)
|
||||
|
||||
|
||||
@@ -42,7 +42,6 @@ class HQQLLMRunner:
|
||||
torch_dtype=compute_dtype,
|
||||
device_map=device,
|
||||
quantization_config=quant_config,
|
||||
low_cpu_mem_usage=True,
|
||||
cache_dir=cache_dir,
|
||||
)
|
||||
self.tokenizer = AutoTokenizer.from_pretrained(model_id, cache_dir=cache_dir)
|
||||
@@ -233,7 +232,9 @@ class HQQSerializationTest(unittest.TestCase):
|
||||
|
||||
# Load and check if the logits match
|
||||
model_loaded = AutoModelForCausalLM.from_pretrained(
|
||||
"quant_model", torch_dtype=torch.float16, device_map=torch_device, low_cpu_mem_usage=True
|
||||
"quant_model",
|
||||
torch_dtype=torch.float16,
|
||||
device_map=torch_device,
|
||||
)
|
||||
|
||||
with torch.no_grad():
|
||||
|
||||
Reference in New Issue
Block a user