How to do image process on a file with 100 image [closed]
Hey guys im trying to do image process on a file with 100 images. This is the code i used to do just one of the image.
img = cv2.imread('frame1.jpg')
mimg = cv2.medianBlur(img,15)
gimg = cv2.cvtColor(mimg,cv2.COLOR_RGB2GRAY)
ret,th1 = cv2.threshold(gimg, 160,255,cv2.THRESH_BINARY)
ret,th2 = cv2.threshold(th1, 160,255,cv2.THRESH_BINARY_INV)
cv2.imwrite('threshbinaryinv.jpg', th2)
There are total of 100 of this images in a folder name "data". Each of the image is named as frame1.jpg , frame2.jpg, frame3.jpg..
I'm trying to get a code that process all 100 image and display them out individually after.
see VideoCapture
but i'm not using video.. its images from a folder name data. theres like 100 of those images
explained in the doc