Face_data = face_data.reshape((face_data.shape[0],-1))

can you pls elaborate this line. Why we apply this line and what is the shpae face_data.

Hey @rakshit20141970, say for example there are 20 images, than this would reshape the values to,
face_data to (20, widthheight3) here 3 is for number of channels if image is captured in ‘rgb’ otherwise in gray scale this 3 factor would not come.

This is done so that, later on knn algorithm could be easily applied.

Hope this resolved your doubt.
Plz mark the doubt as resolved in my doubts section. :blush:

is there any way to print face_data image. for example I save 20 image of mine as name rakshit then can I import this image and print it?

I want to reprint the store image in anthor program

Hey @rakshit20141970, yes you can do that, by
img = face_dataset[ image index]
img = img.reshape((100,100,3)) if you stored them in rgb
img = img.reshape((100,100,1)) if you stored them in grayscale.

Than write your show command for img.
Hope this resolved your doubt.
Plz mark the doubt as resolved in my doubts section. :blush: