creates the database in the local directory

This commit is contained in:
Loic Delattre 2023-02-03 15:07:48 +01:00
parent c5ccacf7e7
commit 5acd9cf279
1 changed files with 4 additions and 3 deletions

View File

@ -5,10 +5,11 @@ import os
import os.path
#create a directory to store the RGB datas ouptut
if os.path.exists(r"C:\Users\cyril\Documents\Loic\Coding\ECAM\PPG_Delattre_Dey\RGB database") == False:
os.mkdir(r"C:\Users\cyril\Documents\Loic\Coding\ECAM\PPG_Delattre_Dey\RGB database")
path_to_script = os.path.dirname(os.path.abspath(__file__))
if os.path.exists(path_to_script + r"\RGB database") == False:
os.mkdir(path_to_script + r"\RGB database")
onlyfiles = next(os.walk(r"C:\Users\cyril\Documents\Loic\Coding\ECAM\PPG_Delattre_Dey\frames"))[2] #get the amount of frames previously extracted
onlyfiles = next(os.walk(path_to_script + r"\frames"))[2] #get the amount of frames previously extracted
frames_num = len(onlyfiles)-1
face_cascade = cv2.CascadeClassifier('haarcascade_frontalface_default.xml')