Spaces:
orrinin
/
Runtime error

orrinin commited on
Commit
7829558
·
verified ·
1 Parent(s): 7885939

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -6
app.py CHANGED
@@ -130,12 +130,9 @@ def generate(
130
  result = job.result()
131
  for file in os.listdir(result):
132
  print(file)
133
- json_file = os.path.join(result,"captions.json")
134
- with open(json_file, 'r') as f:
135
- print(f)
136
- json_data = f
137
- for img in json_data["data"]:
138
- images.append(img)
139
  return images, seed
140
 
141
  examples = [
 
130
  result = job.result()
131
  for file in os.listdir(result):
132
  print(file)
133
+ if file != 'captions.json':
134
+ img_path = os.path.join(result, file)
135
+ images.append(img_path)
 
 
 
136
  return images, seed
137
 
138
  examples = [