Spaces:
Build error
Build error
Commit
·
1ab6079
1
Parent(s):
61cde14
Update app.py
Browse files
app.py
CHANGED
@@ -246,7 +246,7 @@ def pdf_ocr(file, model_t, question):
|
|
246 |
total_output = f'{extracted_values[0][1]} Mq'
|
247 |
text_output = extracted_values[2]
|
248 |
|
249 |
-
immobile_values = [f'{i + 1}. Immobile : {value} Mq\n' for i, value in enumerate(values_output)]
|
250 |
immobile_values = '\n'.join(immobile_values)
|
251 |
|
252 |
return immobile_values, total_output, text_output
|
@@ -286,7 +286,7 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
286 |
with gr.Row():
|
287 |
|
288 |
text_output = gr.components.Textbox(label="Ref. Text")
|
289 |
-
values_output = gr.components.Textbox(label="Area Values")
|
290 |
total_output = gr.components.Textbox(label="Total")
|
291 |
|
292 |
with gr.Row():
|
|
|
246 |
total_output = f'{extracted_values[0][1]} Mq'
|
247 |
text_output = extracted_values[2]
|
248 |
|
249 |
+
immobile_values = [f'{i + 1}. Immobile : {value} Mq\n' for i, value in enumerate(sorted(values_output))]
|
250 |
immobile_values = '\n'.join(immobile_values)
|
251 |
|
252 |
return immobile_values, total_output, text_output
|
|
|
286 |
with gr.Row():
|
287 |
|
288 |
text_output = gr.components.Textbox(label="Ref. Text")
|
289 |
+
values_output = gr.components.Textbox(label="Area Values - sorted by value")
|
290 |
total_output = gr.components.Textbox(label="Total")
|
291 |
|
292 |
with gr.Row():
|