Update module_ocr2.py
Browse files- module_ocr2.py +7 -7
module_ocr2.py
CHANGED
@@ -104,8 +104,8 @@ with gr.Blocks() as demo:
|
|
104 |
label="Upload a PDF or an image file",
|
105 |
file_types=[".pdf", ".jpg", ".jpeg", ".png", ".gif", ".bmp"],
|
106 |
scale=1)
|
107 |
-
preview_image = gr.Image(label="Preview", show_label=True)
|
108 |
-
preview_text = gr.HTML(label="Status")
|
109 |
|
110 |
output_text = gr.Textbox(label="OCR output", scale=2)
|
111 |
|
@@ -128,11 +128,11 @@ with gr.Blocks() as demo:
|
|
128 |
label="Examples"
|
129 |
)
|
130 |
# Update preview when file is uploaded
|
131 |
-
input_file.change(
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
)
|
136 |
|
137 |
# Functions
|
138 |
ocr_btn.click(
|
|
|
104 |
label="Upload a PDF or an image file",
|
105 |
file_types=[".pdf", ".jpg", ".jpeg", ".png", ".gif", ".bmp"],
|
106 |
scale=1)
|
107 |
+
#preview_image = gr.Image(label="Preview", show_label=True)
|
108 |
+
#preview_text = gr.HTML(label="Status")
|
109 |
|
110 |
output_text = gr.Textbox(label="OCR output", scale=2)
|
111 |
|
|
|
128 |
label="Examples"
|
129 |
)
|
130 |
# Update preview when file is uploaded
|
131 |
+
#input_file.change(
|
132 |
+
# fn=preview_file,
|
133 |
+
# inputs=[input_file],
|
134 |
+
# outputs=[preview_image, preview_text]
|
135 |
+
#)
|
136 |
|
137 |
# Functions
|
138 |
ocr_btn.click(
|