multimodalart HF staff commited on
Commit
1dbf257
1 Parent(s): 6477254

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -38,9 +38,9 @@ if not is_spaces:
38
  MAX_IMAGES = 150
39
 
40
 
41
- def load_captioning(uploaded_images, concept_sentence):
42
- uploaded_images = [file for file in uploaded_images if not file.endswith('.txt')]
43
- txt_files = [file for file in uploaded_images if file.endswith('.txt')]
44
  txt_files_dict = {os.path.splitext(os.path.basename(txt_file))[0]: txt_file for txt_file in txt_files}
45
  print(txt_files)
46
  print(txt_files_dict)
 
38
  MAX_IMAGES = 150
39
 
40
 
41
+ def load_captioning(uploaded_files, concept_sentence):
42
+ uploaded_images = [file for file in uploaded_files if not file.endswith('.txt')]
43
+ txt_files = [file for file in uploaded_files if file.endswith('.txt')]
44
  txt_files_dict = {os.path.splitext(os.path.basename(txt_file))[0]: txt_file for txt_file in txt_files}
45
  print(txt_files)
46
  print(txt_files_dict)