From 0d14808ba7680d843768790ba8e0466c029289b7 Mon Sep 17 00:00:00 2001 From: Jim Martens Date: Tue, 2 Jul 2019 11:59:54 +0200 Subject: [PATCH] Added progress bar to data preparation Signed-off-by: Jim Martens --- src/twomartens/masterthesis/data.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/twomartens/masterthesis/data.py b/src/twomartens/masterthesis/data.py index 930c7a7..5cac8eb 100644 --- a/src/twomartens/masterthesis/data.py +++ b/src/twomartens/masterthesis/data.py @@ -29,6 +29,7 @@ from typing import Sequence import numpy as np import scipy import tensorflow as tf +import tqdm from scipy import ndimage from twomartens.masterthesis.ssd_keras.data_generator import object_detection_2d_data_generator, \ @@ -422,7 +423,7 @@ def prepare_scenenet_data(data_path: str, protobuf_path: str) -> Tuple[List[List file_names_photos = [] file_names_instances = [] instances = [] - for trajectory in trajectories.trajectories: + for trajectory in tqdm.tqdm(trajectories.trajectories, desc="preparing trajectories"): path = f"{data_path}/{trajectory.render_path}" file_names_photos_traj = [] file_names_instances_traj = []