diff --git a/deepface/DeepFace.py b/deepface/DeepFace.py index 4b88a1a..de2f38a 100644 --- a/deepface/DeepFace.py +++ b/deepface/DeepFace.py @@ -66,8 +66,15 @@ def verify(img1_path, img2_path='' threshold = functions.findThreshold(model_name, distance_metric) #------------------------------ + pbar = tqdm(range(0,len(img_list)), desc='Verification') + resp_objects = [] - for instance in img_list: + + #for instance in img_list: + for index in pbar: + + instance = img_list[index] + if type(instance) == list and len(instance) >= 2: img1_path = instance[0] img2_path = instance[1] @@ -198,7 +205,12 @@ def analyze(img_path, actions = [], models = {}, enforce_detection = True): #--------------------------------- resp_objects = [] - for img_path in img_paths: + + global_pbar = tqdm(range(0,len(img_paths)), desc='Analyzing') + + #for img_path in img_paths: + for j in global_pbar: + img_path = img_paths[j] resp_obj = "{" diff --git a/setup.py b/setup.py index fe78f18..c317192 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ with open("README.md", "r", encoding="utf-8") as fh: setuptools.setup( name="deepface", - version="0.0.21", + version="0.0.22", author="Sefik Ilkin Serengil", author_email="serengil@gmail.com", description="Deep Face Analysis Framework for Face Recognition and Demography", diff --git a/tests/unit_tests.py b/tests/unit_tests.py index 1642086..83a5610 100644 --- a/tests/unit_tests.py +++ b/tests/unit_tests.py @@ -153,4 +153,4 @@ facial_attribute_models["age"] = age_model facial_attribute_models["gender"] = gender_model facial_attribute_models["race"] = race_model -resp_obj = DeepFace.analyze("dataset/img1.jpg", models=facial_attribute_models) \ No newline at end of file +resp_obj = DeepFace.analyze("dataset/img1.jpg", models=facial_attribute_models)