Upload infer_1.py with huggingface_hub
Browse files- infer_1.py +1 -1
infer_1.py
CHANGED
|
@@ -16,7 +16,7 @@ def write_json(file_path, data):
|
|
| 16 |
json.dump(data, file, ensure_ascii=False, indent=4)
|
| 17 |
|
| 18 |
# default: Load the model on the available device(s)
|
| 19 |
-
|
| 20 |
model_path = "/home/zbz5349/WorkSpace/aigeeks/Qwen2.5-VL/ckpt"
|
| 21 |
model = Qwen2_5_VLForConditionalGeneration.from_pretrained(
|
| 22 |
model_path, torch_dtype="auto", device_map="auto"
|
|
|
|
| 16 |
json.dump(data, file, ensure_ascii=False, indent=4)
|
| 17 |
|
| 18 |
# default: Load the model on the available device(s)
|
| 19 |
+
print(torch.cuda.device_count())
|
| 20 |
model_path = "/home/zbz5349/WorkSpace/aigeeks/Qwen2.5-VL/ckpt"
|
| 21 |
model = Qwen2_5_VLForConditionalGeneration.from_pretrained(
|
| 22 |
model_path, torch_dtype="auto", device_map="auto"
|