Spaces:
Paused
Paused
Update inference.py
Browse files- inference.py +5 -2
inference.py
CHANGED
|
@@ -75,8 +75,11 @@ def process_document(image):
|
|
| 75 |
parsed = json.loads(response)
|
| 76 |
except:
|
| 77 |
parsed = {
|
| 78 |
-
"error":
|
| 79 |
-
|
|
|
|
|
|
|
|
|
|
| 80 |
}
|
| 81 |
|
| 82 |
return parsed
|
|
|
|
| 75 |
parsed = json.loads(response)
|
| 76 |
except:
|
| 77 |
parsed = {
|
| 78 |
+
"error":[
|
| 79 |
+
response
|
| 80 |
+
]
|
| 81 |
+
# "Invalid JSON",
|
| 82 |
+
# "raw": response
|
| 83 |
}
|
| 84 |
|
| 85 |
return parsed
|