File size: 498 Bytes
4a8795e
 
 
 
 
5b573a3
 
4a8795e
 
 
 
 
 
 
 
 
41ca7cb
 
4a8795e
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import gradio
import cv2


def inference(img):
  my_result = cv2.erode(img,(25,25)).dilate(img,(25,25))
  return my_result

# For information on Interfaces, head to https://gradio.app/docs/
# For user guides, head to https://gradio.app/guides/
# For Spaces usage, head to https://huggingface.co/docs/hub/spaces
iface = gradio.Interface(
  fn=inference,
  inputs='image',
  outputs='image',
  title='Hello World', 
  description='The simplest interface!',
  examples=["llama.jpg"])  

iface.launch()