Spaces:
Build error
Build error
TzuShianYang
commited on
Commit
·
d9e620f
1
Parent(s):
3bf8c66
Fix datetime error
Browse files
app.py
CHANGED
|
@@ -1,6 +1,5 @@
|
|
| 1 |
import gradio as gr
|
| 2 |
import zipfile
|
| 3 |
-
import os
|
| 4 |
import datetime
|
| 5 |
|
| 6 |
|
|
@@ -14,7 +13,7 @@ def add_image(camera, gallery):
|
|
| 14 |
|
| 15 |
|
| 16 |
def zip_gallery(gallery):
|
| 17 |
-
new_zip_name = f'{datetime.
|
| 18 |
count = 0
|
| 19 |
if not gallery:
|
| 20 |
return gr.DownloadButton("Download", visible=False)
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
import zipfile
|
|
|
|
| 3 |
import datetime
|
| 4 |
|
| 5 |
|
|
|
|
| 13 |
|
| 14 |
|
| 15 |
def zip_gallery(gallery):
|
| 16 |
+
new_zip_name = f'{datetime.datetime.now().strftime("%Y_%m_%d_%H_%M_%S")}.zip'
|
| 17 |
count = 0
|
| 18 |
if not gallery:
|
| 19 |
return gr.DownloadButton("Download", visible=False)
|