Spaces:
Sleeping
Sleeping
Update player.py
Browse files
player.py
CHANGED
@@ -84,8 +84,8 @@ def show_vid(vid_file,list_hid):
|
|
84 |
##############################################
|
85 |
|
86 |
#def build_space(t_space,t_title,t_description=None,t_name=None,t_redirect=None,t_image=None,t_image_url=None,token=None):
|
87 |
-
def build_space(vid_file):
|
88 |
-
print(vid_file)
|
89 |
file_in = f'https://huggingface.co/datasets/jbilcke-hf/ai-tube-index/blob/main/{vid_file}'
|
90 |
|
91 |
|
@@ -232,5 +232,5 @@ with gr.Blocks() as app:
|
|
232 |
app.load(find_dataset,None,channel)
|
233 |
channel.change(load_vid,channel,[output,videos,list_hid])
|
234 |
videos.change(show_vid,[videos,list_hid],[label_output])
|
235 |
-
button.click(build_space,list_hid,None)
|
236 |
app.launch(show_api=False,share=False)
|
|
|
84 |
##############################################
|
85 |
|
86 |
#def build_space(t_space,t_title,t_description=None,t_name=None,t_redirect=None,t_image=None,t_image_url=None,token=None):
|
87 |
+
def build_space(index_sel, vid_file):
|
88 |
+
print(vid_file[int(index_sel)])
|
89 |
file_in = f'https://huggingface.co/datasets/jbilcke-hf/ai-tube-index/blob/main/{vid_file}'
|
90 |
|
91 |
|
|
|
232 |
app.load(find_dataset,None,channel)
|
233 |
channel.change(load_vid,channel,[output,videos,list_hid])
|
234 |
videos.change(show_vid,[videos,list_hid],[label_output])
|
235 |
+
button.click(build_space,[videos,list_hid],None)
|
236 |
app.launch(show_api=False,share=False)
|