Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,7 +20,7 @@ from prompts import front as front_prompt, back as back_prompt
|
|
| 20 |
# ---------------------------
|
| 21 |
# HUGGING FACE MODEL SETUP (CPU)
|
| 22 |
# ---------------------------
|
| 23 |
-
path = "OpenGVLab/InternVL2_5-
|
| 24 |
cache_folder = "./.cache"
|
| 25 |
|
| 26 |
# Load the Vision AI model and tokenizer globally.
|
|
@@ -143,7 +143,7 @@ def vision_ai_api(image, doc_type):
|
|
| 143 |
gc.collect() # Force garbage collection
|
| 144 |
torch.cuda.empty_cache()
|
| 145 |
|
| 146 |
-
return f'
|
| 147 |
|
| 148 |
# ---------------------------
|
| 149 |
# PREDICTION PIPELINE
|
|
|
|
| 20 |
# ---------------------------
|
| 21 |
# HUGGING FACE MODEL SETUP (CPU)
|
| 22 |
# ---------------------------
|
| 23 |
+
path = "OpenGVLab/InternVL2_5-1B"
|
| 24 |
cache_folder = "./.cache"
|
| 25 |
|
| 26 |
# Load the Vision AI model and tokenizer globally.
|
|
|
|
| 143 |
gc.collect() # Force garbage collection
|
| 144 |
torch.cuda.empty_cache()
|
| 145 |
|
| 146 |
+
return f'{response}'
|
| 147 |
|
| 148 |
# ---------------------------
|
| 149 |
# PREDICTION PIPELINE
|