问题
I am using Emgu CV (v2.4) with C#. In the following class. I need to modify the data type of the used column in the table to array.
public void FindSURF(Image<Gray, Byte> modelImage)
{
VectorOfKeyPoint modelKeyPoints;
SURFDetector surfCPU = new SURFDetector(500, false);
//extract features from the object image
modelKeyPoints = new VectorOfKeyPoint();
Matrix<float> modelDescriptors = surfCPU.DetectAndCompute(modelImage, null, modelKeyPoints);
}
the SURF feature extract and store in Matrix<float> modelDescriptors
how can I modify this datatype to array?
回答1:
You could use the property from the Matrix
:
float[] elements = modelDescriptors.Elements;
来源:https://stackoverflow.com/questions/38369572/how-to-modify-datatype-of-matrixfloat-to-array