Karumoon commited on
Commit
876f731
·
1 Parent(s): 14d8fe5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -1
app.py CHANGED
@@ -198,4 +198,21 @@ def is_google_colab():
198
  return False
199
 
200
  is_colab=is_google_colab()
201
- demo.launch(debug=is_colab, share=is_colab)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
198
  return False
199
 
200
  is_colab=is_google_colab()
201
+
202
+ def emb():
203
+ with gr.Blocks(css="cake.css") as myface:
204
+ gr.HTML("""<head><meta http-equiv="refresh" content="180"></head>""")
205
+ def sesh_start():
206
+ img = Image.open("nsfw.PNG")
207
+ image_mod(img)
208
+ #t = time.gmtime()
209
+ t_stamp = time.time()
210
+ #current_time = time.strftime("%H:%M:%S", t)
211
+ return gr.update(value=t_stamp),gr.update(value=t_stamp),gr.update(value=0)
212
+ run=gr.Button("Launch")
213
+ run.click(sesh_start,None,[start_box,end_box,tog_box])
214
+
215
+ #demo.launch(debug=is_colab, share=is_colab)
216
+ #(inline=True,show_api=False)
217
+ emb()
218
+ myface.launch(debug=is_colab, share=is_colab,inline=True,show_api=False)