OpenCV Q&A Forum - RSS feedhttp://answers.opencv.org/questions/OpenCV answersenCopyright <a href="http://www.opencv.org">OpenCV foundation</a>, 2012-2018.Tue, 21 May 2013 16:04:40 -0500Reshaping matrices into column vectors??http://answers.opencv.org/question/13658/reshaping-matrices-into-column-vectors/Hi,
I have a question regarding reshaping matrices. I have two square 3x3 matrices M1 and M2. I wish to turn both matrices into 9 element column vectors c1 and c2. Next i would like to create a new matrix consisting of new 2x9 matrix [c1,c2]. I need to do this in order to solve a least square problem.
I tried using the reshape function as M1.reshape(0,9) but it returns:
OpenCV Error: Image step is wrong (The matrix is not continuous, thus its number of rows can not be changed) in reshapenapoleonTue, 21 May 2013 16:04:40 -0500http://answers.opencv.org/question/13658/