Skip to content

Commit faeeb36

Browse files
committed
Merge branch 'master' of https://github.com/Zielon/INSTA
2 parents 0c06b70 + 3dc6f86 commit faeeb36

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scripts/transforms.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -165,11 +165,13 @@ def dump_frame(payload):
165165

166166
create_input_images(src, f'{output}/background/')
167167

168+
data['frames'] = [None] * len(frames)
168169
with Pool(processes=8) as pool:
169170
params = [(frames[i], src, output) for i in range(len(frames))]
170171
for task in tqdm(pool.imap_unordered(dump_frame, params), total=len(frames)):
171172
if task is not None:
172-
data['frames'].append(task)
173+
id = int(Path(task['file_path']).stem)
174+
data['frames'][id] = task
173175

174176
for f in data["frames"]:
175177
f["transform_matrix"] = f["transform_matrix"].tolist()

0 commit comments

Comments
 (0)