epishchik commited on
Commit
5b4fab1
1 Parent(s): 083d4cc
Files changed (1) hide show
  1. super-resolution-games.py +7 -6
super-resolution-games.py CHANGED
@@ -164,11 +164,12 @@ class SuperResolutionGames(datasets.GeneratorBasedBuilder):
164
  return splits
165
 
166
  def _generate_examples(self, r270p, r360p, r540p, r1080p):
167
- for el1, el2, el3, el4 in zip(r270p, r360p, r540p, r1080p):
 
168
  sample = {
169
- '270p': [el1[0], el1[1].read()],
170
- '360p': [el2[0], el2[1].read()],
171
- '540p': [el3[0], el3[1].read()],
172
- '1080p': [el4[0], el4[1].read()]
173
  }
174
- yield sample
 
164
  return splits
165
 
166
  def _generate_examples(self, r270p, r360p, r540p, r1080p):
167
+ for idx, resolutions in enumerate(zip(r270p, r360p, r540p, r1080p)):
168
+ r270p_i, r360p_i, r540p_i, r1080p_i = resolutions
169
  sample = {
170
+ '270p': [r270p_i[0], r270p_i[1].read()],
171
+ '360p': [r360p_i[0], r360p_i[1].read()],
172
+ '540p': [r540p_i[0], r540p_i[1].read()],
173
+ '1080p': [r1080p_i[0], r1080p_i[1].read()]
174
  }
175
+ yield idx, sample