I've created folder structures with code on my desktop, and filled them with images using the cap=cv2.VideoCapture() with no problem.
To create folder structures and make directories, I wrote this code and it works fine:
#SETUP PATHS
POS_PATH = os.path.join('data', 'positive')
NEG_PATH = os.path.join('data', 'negative')
ANC_PATH = os.path.join('data','anchor')
#MAKE DIRECTORIES
os.makedirs(POS_PATH)
os.makedirs(NEG_PATH)
os.makedirs(ANC_PATH)
But, when I want to list images in a file, I get this error:
os.listdir('positive')
ERROR: FileNotFoundError: [WinError 3] The system cannot find the path specified: 'positive'
Can you help me?