Untitled
unknown
plain_text
6 months ago
850 B
7
Indexable
Never
spoofcaffe = "detection_model/Widerface-RetinaFace.caffemodel" spoofcaffe_path = os.path.dirname(os.path.abspath(__file__)) caffemodel = os.path.join(spoofcaffe_path,spoofcaffe) if(not os.path.exists(caffemodel)): print("[FAIL] caffemodel is does not exist.. (path hatasi) path: "+ caffemodel) spoofdeploy = "detection_model/deploy.prototxt" spoofdeploy_path = os.path.dirname(os.path.abspath(__file__)) deploy = os.path.join(spoofdeploy_path,spoofdeploy) if(not os.path.exists(deploy)): print("[FAIL] deploy is does not exist.. (path hatasi) path: "+deploy) caffemodel = caffemodel.replace("\\","/") deploy = deploy.replace("\\","/") self.detector = cv2.dnn.readNetFromCaffe(deploy, caffemodel)