Spaces:
Paused
Paused
FlawedLLM commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -13,9 +13,8 @@ import torch
|
|
| 13 |
import spaces
|
| 14 |
|
| 15 |
model_id = "microsoft/Phi-3-vision-128k-instruct"
|
| 16 |
-
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="
|
| 17 |
processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True)
|
| 18 |
-
model.to("cuda:0")
|
| 19 |
|
| 20 |
from PIL import Image
|
| 21 |
import base64
|
|
|
|
| 13 |
import spaces
|
| 14 |
|
| 15 |
model_id = "microsoft/Phi-3-vision-128k-instruct"
|
| 16 |
+
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto", trust_remote_code=True, torch_dtype="auto")
|
| 17 |
processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True)
|
|
|
|
| 18 |
|
| 19 |
from PIL import Image
|
| 20 |
import base64
|