First time here? Check out the FAQ!
answered 2016-04-06 02:29:13 -0600
trainClasses.create(trainingData.rows, 12, CV_32FC1); does not initialize data, i guess, you wanted something like: trainClasses = Mat::zeros(trainingData.rows, 12, CV_32FC1);
trainClasses.create(trainingData.rows, 12, CV_32FC1);
trainClasses = Mat::zeros(trainingData.rows, 12, CV_32FC1);