1e619d91956c813d2328a5460da0a273fe135905,hook/zmes_hook_helpers/face.py,Face,detect,#Face#Any#,123

Before Change



            if best_pred >= g.config["face_recog_min_confidence"]:
                 matched_face_names.append(self.svm_model.classes_[best_pred_ndx])
                 g.logger.debug("face:{} matched with confidence: {}".format(self.svm_model.classes_[best_pred_ndx], best_pred))
            else:     
                g.logger.debug ("face matched:{} but confidence of:{} is less than {}, marking it unknown".format(self.svm_model.classes_[best_pred_ndx], best_pred, g.config["face_recog_min_confidence"]))
                matched_face_names.append(g.config["unknown_face_name"])
                best_pred = 1 // if unknown, don"t carry over pred prob

After Change


        face_encodings = face_recognition.face_encodings(rgb_image, known_face_locations=face_locations, num_jitters=self.num_jitters)

        // Use the KNN model to find the best matches for the test face
        closest_distances = self.knn.kneighbors(face_encodings, n_neighbors=1)
        are_matches = [closest_distances[0][i][0] <= g.config["face_recog_dist_threshold"] for i in range(len(face_locations))]

        matched_face_names = []
        matched_face_rects = []
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: pliablepixels/zmeventnotification
Commit Name: 1e619d91956c813d2328a5460da0a273fe135905
Time: 2019-11-15
Author: pliablepixels@gmail.com
File Name: hook/zmes_hook_helpers/face.py
Class Name: Face
Method Name: detect


Project Name: pantsbuild/pants
Commit Name: dd78698ca28b40e40431449f84a3d5cf970865e3
Time: 2015-07-06
Author: zundel@squareup.com
File Name: src/python/pants/backend/jvm/tasks/ivy_resolve.py
Class Name: IvyResolve
Method Name: execute


Project Name: vatlab/SoS
Commit Name: c8788d2eedcdb2671289d7d47a41b8fdcb0294f1
Time: 2017-09-11
Author: ben.bog@gmail.com
File Name: src/sos/sos_executor.py
Class Name: Base_Executor
Method Name: resolve_dangling_targets