Spaces:
Running
on
Zero
Running
on
Zero
Update demo/infer.py
Browse files- demo/infer.py +1 -1
demo/infer.py
CHANGED
@@ -35,7 +35,7 @@ class LiveCCDemoInfer:
|
|
35 |
def __init__(self, model_path: str = None, device_id: int = 0):
|
36 |
self.model = Qwen2VLForConditionalGeneration.from_pretrained(
|
37 |
model_path, torch_dtype="auto",
|
38 |
-
device_map=f'cuda:{device_id}',
|
39 |
# attn_implementation='flash_attention_2'
|
40 |
)
|
41 |
self.processor = AutoProcessor.from_pretrained(model_path, use_fast=False)
|
|
|
35 |
def __init__(self, model_path: str = None, device_id: int = 0):
|
36 |
self.model = Qwen2VLForConditionalGeneration.from_pretrained(
|
37 |
model_path, torch_dtype="auto",
|
38 |
+
# device_map=f'cuda:{device_id}',
|
39 |
# attn_implementation='flash_attention_2'
|
40 |
)
|
41 |
self.processor = AutoProcessor.from_pretrained(model_path, use_fast=False)
|