import gradio as gr | |
from PIL import Image | |
def resize_image(img, W, H): | |
resized_img = img.resize((W, H)) | |
return resized_img | |
iface = gr.Interface( | |
fn=resize_image, | |
inputs=["image", "number", "number"], | |
outputs="image" | |
) | |
iface.launch() | |
import gradio as gr | |
from PIL import Image | |
def resize_image(img, W, H): | |
resized_img = img.resize((W, H)) | |
return resized_img | |
iface = gr.Interface( | |
fn=resize_image, | |
inputs=["image", "number", "number"], | |
outputs="image" | |
) | |
iface.launch() | |