(-13) Matrix error in Eigenfaces model (Face Recognizer)
Hi guys, I've been experiencing this error on Eigenfaces.cpp:
OpenCV Error: Image step is wrong (The matrix is not continuous, thus its number of rows can not be changed) in reshape, file terminate called after trowing an instance of 'cv::Exception'
what (): /home/pi/opencv-2.4.8/modules/core/src/matrix.cpp: 802: error: (-13) The matrix is not continuous, thus its number of rows can not be changed in function reshape
I downloaded a pack of 400 faces, but I don't know what this error is about. It is about the faces, the filters or algorythm problem?
It is called on the 'reshape' method
// perform the PCA
PCA pca(data, Mat(), CV_PCA_DATA_AS_ROW, _num_components);
// copy the PCA results
_mean = pca.mean.reshape(1,1); // store the mean vector
Edit: I'm using OpenCv 2.4.8
that is a bit weird. are you really sure that this is the correct reshape() call (there are 6 in facerec.cpp) ? not when processing the images ?
http://stackoverflow.com/questions/21937711/opencv-error-image-step-is-wrong-the-matrix-is-not-continuous