SalmanAboAraj commited on
Commit
a47c5f2
·
verified ·
1 Parent(s): fb2e8a9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -13
app.py CHANGED
@@ -57,19 +57,16 @@ def predict(image):
57
  return mask_final
58
 
59
  # إنشاء واجهة Gradio
60
- with gr.Blocks() as iface:
61
- gr.Markdown("# Tooth Segmentation Model")
62
- gr.Markdown("Upload a dental X-ray image to generate the annotation mask.")
63
-
64
- with gr.Row():
65
- with gr.Column():
66
- input_image = gr.File(label="Input X-ray Image")
67
- submit_button = gr.Button("Predict")
68
-
69
- with gr.Column():
70
- output_image = gr.File(label="Annotation Mask")
71
-
72
  submit_button.click(fn=predict, inputs=input_image, outputs=output_image)
73
-
74
  if __name__ == "__main__":
75
  iface.launch()
 
57
  return mask_final
58
 
59
  # إنشاء واجهة Gradio
60
+ with gr.Blocks() as iface:
61
+ gr.Markdown("# Tooth Segmentation Model")
62
+ gr.Markdown("Upload a dental X-ray image to generate the annotation mask.")
63
+ with gr.Row():
64
+ with gr.Column():
65
+ input_image = gr.Image(label="Input X-ray Image", type="numpy")
66
+ submit_button = gr.Button("Predict")
67
+ with gr.Column():
68
+ output_image = gr.Image(label="Annotation Mask", type="numpy")
69
+
 
 
70
  submit_button.click(fn=predict, inputs=input_image, outputs=output_image)
 
71
  if __name__ == "__main__":
72
  iface.launch()