Rodrigo_Cobo commited on
Commit
d8eaf88
1 Parent(s): e32d51c

change output to image

Browse files
Files changed (1) hide show
  1. app.py +5 -0
app.py CHANGED
@@ -1,6 +1,11 @@
 
1
  import gradio as gr
 
2
  def update(img):
3
 
 
 
 
4
  img.save("temp/image.jpg", "JPEG")
5
 
6
  return f'temp/image.jpg'
 
1
+ import os
2
  import gradio as gr
3
+
4
  def update(img):
5
 
6
+ if not os.path.exists('temp'):
7
+ os.system('mkdir temp')
8
+
9
  img.save("temp/image.jpg", "JPEG")
10
 
11
  return f'temp/image.jpg'