Path_(Image number).jpg for images that showed the path

cv2.imwrite("path/path-" + str(i) + ".jpg", img)

Right_(Image number).jpg for images that showed the obstacles on the right side of the path

cv2.imwrite("right/right-" + str(i) + ".jpg", img)

Left_(Image number).jpg for images that showed the obstacles on the left side of the path

cv2.imwrite("left/left-" + str(i) + ".jpg", img)