Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -16,8 +16,8 @@ def infer_diagram(image, question):
|
|
| 16 |
|
| 17 |
@spaces.GPU
|
| 18 |
def infer_ocrvqa(image, question):
|
| 19 |
-
model =
|
| 20 |
-
processor =
|
| 21 |
|
| 22 |
inputs = processor(images=image,text=question, return_tensors="pt").to("cuda")
|
| 23 |
|
|
|
|
| 16 |
|
| 17 |
@spaces.GPU
|
| 18 |
def infer_ocrvqa(image, question):
|
| 19 |
+
model = PaliGemmaForConditionalGeneration.from_pretrained("google/paligemma-3b-ft-ocrvqa-896").to("cuda")
|
| 20 |
+
processor = PaliGemmaProcessor.from_pretrained("google/paligemma-3b-ft-ocrvqa-896e")
|
| 21 |
|
| 22 |
inputs = processor(images=image,text=question, return_tensors="pt").to("cuda")
|
| 23 |
|