Leon4gr45 commited on
Commit
dcfb6cb
·
verified ·
1 Parent(s): 8b44be5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -17,8 +17,9 @@ model_id = "OpenGVLab/InternVL2_5-2B"
17
  model = AutoModel.from_pretrained(
18
  model_id,
19
  trust_remote_code=True,
20
- torch_dtype=torch.bfloat16, # <--- CRITICAL CHANGE: Reduces RAM usage by 50%
21
- low_cpu_mem_usage=True # <--- HELPFUL: Prevents RAM spikes during loading
 
22
  ).to(device).eval()
23
  tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
24
 
 
17
  model = AutoModel.from_pretrained(
18
  model_id,
19
  trust_remote_code=True,
20
+ torch_dtype=torch.bfloat16,
21
+ low_cpu_mem_usage=True,
22
+ revision="65b9340"
23
  ).to(device).eval()
24
  tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
25