SmartHeal commited on
Commit
2b90bf7
·
verified ·
1 Parent(s): e4c8717

Update src/ai_processor.py

Browse files
Files changed (1) hide show
  1. src/ai_processor.py +1 -1
src/ai_processor.py CHANGED
@@ -149,7 +149,7 @@ def _vlm_infer_gpu(messages, model_id: str, max_new_tokens: int, token: Optional
149
  task="image-text-to-text",
150
  model=model_id,
151
  torch_dtype=torch.bfloat16, # Use torch_dtype from the working example
152
- device_map="auto", # CUDA init happens here, safely in GPU worker
153
  token=token,
154
  trust_remote_code=True,
155
  model_kwargs={"low_cpu_mem_usage": True},
 
149
  task="image-text-to-text",
150
  model=model_id,
151
  torch_dtype=torch.bfloat16, # Use torch_dtype from the working example
152
+ device_map=0, # CUDA init happens here, safely in GPU worker
153
  token=token,
154
  trust_remote_code=True,
155
  model_kwargs={"low_cpu_mem_usage": True},