Dabs commited on
Commit
e9e6fef
1 Parent(s): ce5b03d

innitial commit

Browse files
Files changed (2) hide show
  1. .gitignore +1 -0
  2. app.py +16 -0
.gitignore ADDED
@@ -0,0 +1 @@
 
 
1
+ venv/
app.py ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import numpy as np
2
+
3
+ import gradio as gr
4
+
5
+ def quantize(val):
6
+ return (np.round(val / 255) * 255).astype(np.uint8)
7
+
8
+
9
+ def sepia(input_img):
10
+ output_img = list(map(quantize, input_img))
11
+ return output_img
12
+
13
+
14
+ iface = gr.Interface(sepia, "image", "pil")
15
+
16
+ iface.launch()