Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -14,8 +14,8 @@ model_id = "vikhyatk/moondream2"
|
|
14 |
revision = "2024-04-02"
|
15 |
tokenizer = AutoTokenizer.from_pretrained(model_id, revision=revision)
|
16 |
moondream = AutoModelForCausalLM.from_pretrained(
|
17 |
-
model_id, trust_remote_code=True, revision=revision
|
18 |
-
).to(device=device
|
19 |
moondream.eval()
|
20 |
|
21 |
@spaces.GPU(duration=10)
|
|
|
14 |
revision = "2024-04-02"
|
15 |
tokenizer = AutoTokenizer.from_pretrained(model_id, revision=revision)
|
16 |
moondream = AutoModelForCausalLM.from_pretrained(
|
17 |
+
model_id, trust_remote_code=True, revision=revision, torch_dtype=dtype
|
18 |
+
).to(device=device)
|
19 |
moondream.eval()
|
20 |
|
21 |
@spaces.GPU(duration=10)
|