uttarasawant commited on
Commit
f76eae9
·
verified ·
1 Parent(s): 06ac1dc

Update for peft_model

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -35,7 +35,9 @@ def load_model_and_adapters():
35
  )
36
  print("Loading your fine-tuned fridge adapters...")
37
  # PEFT will look at base_model's device map to assign tensor locations safely
38
- peft_model = PeftModel.from_pretrained(base, "uttarasawant/qwen2.5-vl-fridge-adapters")
 
 
39
 
40
  return peft_model
41
 
 
35
  )
36
  print("Loading your fine-tuned fridge adapters...")
37
  # PEFT will look at base_model's device map to assign tensor locations safely
38
+ #peft_model = PeftModel.from_pretrained(base, "uttarasawant/qwen2.5-vl-fridge-adapters")
39
+ # Force safetensors to read the file into CPU memory first, bypassing the boot-time CUDA check
40
+ peft_model = PeftModel.from_pretrained(base, "uttarasawant/qwen2.5-vl-fridge-adapters", low_cpu_mem_usage=True)
41
 
42
  return peft_model
43