Update app.py
Browse files
app.py
CHANGED
@@ -8,11 +8,11 @@ with gr.Blocks() as demo:
|
|
8 |
gr.Markdown("## Sketchpad Visualization")
|
9 |
with gr.Row():
|
10 |
with gr.Column():
|
11 |
-
sketchpad = gr.
|
12 |
with gr.Column():
|
13 |
output_image = gr.Image(type="numpy", label="Your Sketch")
|
14 |
|
15 |
-
sketchpad.
|
16 |
|
17 |
if __name__ == "__main__":
|
18 |
demo.launch()
|
|
|
8 |
gr.Markdown("## Sketchpad Visualization")
|
9 |
with gr.Row():
|
10 |
with gr.Column():
|
11 |
+
sketchpad = gr.Sketchpad(shape=(256, 256), label="Draw Something")
|
12 |
with gr.Column():
|
13 |
output_image = gr.Image(type="numpy", label="Your Sketch")
|
14 |
|
15 |
+
sketchpad.submit(fn=display_sketch, inputs=sketchpad, outputs=output_image)
|
16 |
|
17 |
if __name__ == "__main__":
|
18 |
demo.launch()
|