Spaces:
Running
Running
Commit
·
84f3cde
1
Parent(s):
d812fea
Added text
Browse files
app.py
CHANGED
@@ -103,6 +103,20 @@ def main(det_archs, reco_archs):
|
|
103 |
print('\n')
|
104 |
print('page_export',page_export)
|
105 |
print('\n')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
106 |
|
107 |
# Display JSON
|
108 |
st.markdown("\nHere are your analysis results in JSON format:")
|
|
|
103 |
print('\n')
|
104 |
print('page_export',page_export)
|
105 |
print('\n')
|
106 |
+
all_text = ''
|
107 |
+
for i in page_export['blocks']:
|
108 |
+
for line in i['lines']:
|
109 |
+
for word in line['words']:
|
110 |
+
all_text+=word['value']
|
111 |
+
all_text+=' '
|
112 |
+
all_text+='\n'
|
113 |
+
|
114 |
+
print('all_text', all_text)
|
115 |
+
print('\n')
|
116 |
+
|
117 |
+
# Display Text
|
118 |
+
st.markdown("\nHere is your text:")
|
119 |
+
st.write(all_text)
|
120 |
|
121 |
# Display JSON
|
122 |
st.markdown("\nHere are your analysis results in JSON format:")
|