Commit
·
17da5da
1
Parent(s):
9065127
Update app.py
Browse files
app.py
CHANGED
|
@@ -132,9 +132,9 @@ def generate_ocr(Method,img):
|
|
| 132 |
if Method == 'PaddleOCR':
|
| 133 |
text_output = ocr_with_paddle(img)
|
| 134 |
|
| 135 |
-
|
| 136 |
-
|
| 137 |
-
add_csv = [Method,
|
| 138 |
|
| 139 |
with open(DATA_FILE, "a") as f:
|
| 140 |
writer = csv.writer(f)
|
|
|
|
| 132 |
if Method == 'PaddleOCR':
|
| 133 |
text_output = ocr_with_paddle(img)
|
| 134 |
|
| 135 |
+
new_data=img.reshape(img.shape)
|
| 136 |
+
imge = Image.fromarray(new_data.astype(np.uint8),'RGB')
|
| 137 |
+
add_csv = [Method,imge,text_output]
|
| 138 |
|
| 139 |
with open(DATA_FILE, "a") as f:
|
| 140 |
writer = csv.writer(f)
|