def echo_image(image): return image demo = gr.Interface( fn=echo_image, inputs=[ gr.components.Image(type="pil", shape=(512, 512)), ], outputs=[ gr.components.Image(type="pil", shape=(512, 512), label="output-1") ], ) demo.launch(inline=False)