Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -50,16 +50,18 @@ def save_text(text):
|
|
50 |
|
51 |
|
52 |
# Create Gradio interface
|
53 |
-
with gr.Blocks(title="
|
54 |
-
gr.Markdown("#
|
55 |
-
gr.Markdown(
|
|
|
|
|
56 |
|
57 |
with gr.Row():
|
58 |
-
input_file = gr.File(label="Upload JSON
|
59 |
|
60 |
with gr.Row():
|
61 |
-
output_text = gr.Textbox(label="Converted
|
62 |
-
download_btn = gr.DownloadButton(label="Download
|
63 |
|
64 |
# Connect the components
|
65 |
input_file.change(fn=process_metadata, inputs=[input_file], outputs=[output_text])
|
|
|
50 |
|
51 |
|
52 |
# Create Gradio interface
|
53 |
+
with gr.Blocks(title="VL-HF Annotations Converter") as iface:
|
54 |
+
gr.Markdown("# VL-HF Annotations Converter")
|
55 |
+
gr.Markdown(
|
56 |
+
"Upload a JSON annotations file exported from Visual Layer and get a JSONL file to be used in Hugging Face AutoTrain."
|
57 |
+
)
|
58 |
|
59 |
with gr.Row():
|
60 |
+
input_file = gr.File(label="Upload JSON file exported from Visual Layer")
|
61 |
|
62 |
with gr.Row():
|
63 |
+
output_text = gr.Textbox(label="Converted JSONL output", lines=10)
|
64 |
+
download_btn = gr.DownloadButton(label="Download JSONL", interactive=True)
|
65 |
|
66 |
# Connect the components
|
67 |
input_file.change(fn=process_metadata, inputs=[input_file], outputs=[output_text])
|