Spaces:
Running
on
Zero
Running
on
Zero
wjbmattingly
commited on
Commit
•
5adbad8
1
Parent(s):
cc1b97c
redesigned layout
Browse files
app.py
CHANGED
@@ -143,16 +143,18 @@ def gradio_process_document(image, model_name):
|
|
143 |
return output_image, transcriptions
|
144 |
|
145 |
with gr.Blocks() as iface:
|
146 |
-
gr.Markdown("#
|
147 |
gr.Markdown("Upload an image and select a model to detect lines and transcribe the text.")
|
148 |
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
|
|
|
|
153 |
|
154 |
with gr.Row():
|
155 |
-
output_image = gr.Image(type="pil", label="Detected Lines")
|
156 |
output_text = gr.Textbox(label="Transcription")
|
157 |
|
158 |
submit_button.click(
|
|
|
143 |
return output_image, transcriptions
|
144 |
|
145 |
with gr.Blocks() as iface:
|
146 |
+
gr.Markdown("# Medieval Manuscript Line Detection and HTR App")
|
147 |
gr.Markdown("Upload an image and select a model to detect lines and transcribe the text.")
|
148 |
|
149 |
+
|
150 |
+
with gr.Row():
|
151 |
+
input_image = gr.Image(type="pil", label="Upload Image", height=300, width=300) # Adjusted size here
|
152 |
+
with gr.Column():
|
153 |
+
model_dropdown = gr.Dropdown(choices=list(MODEL_OPTIONS.keys()), value="Medieval Base", label="Select Model")
|
154 |
+
submit_button = gr.Button("Process")
|
155 |
|
156 |
with gr.Row():
|
157 |
+
output_image = gr.Image(type="pil", label="Detected Lines", height=500, width=500)
|
158 |
output_text = gr.Textbox(label="Transcription")
|
159 |
|
160 |
submit_button.click(
|