Home > Software engineering >  In VC2012 Dense SIFT Feature extraction characteristics when _CtrIsValidHeapPointer (pUserData) prob
In VC2012 Dense SIFT Feature extraction characteristics when _CtrIsValidHeapPointer (pUserData) prob

Time:02-12

The code is as follows:
It's a cycle from one folder to read all of the pictures and images one by one to analyze its Dense SIFT features and unified operation, preservation here at run to Ptr Fdetector (new DenseFeatureDetector (initFeatureScale featureScaleLevels, featureScaleMul, initXyStep, initImgBound, false)); After this statement (statement) and after the comment after the jump out of the loop will give _CtrIsValidHeapPointer (pUserData) problems, try to use the release operation still has a problem, could you tell me how should solve? Whether the opencv or vc built-in bug?
For (count=0; The count & lt; ImgNum; Count++) {
Mat img=imread (wkDir + namesNE [count] + "PNG");
Height=img. Rows;
Width=img. Cols;
//SiftFeatureDetector siftdtc;
Float initFeatureScale=1.5 f, featureScaleMul=1.5 f;
Int featureScaleLevels=8, initXyStep=2, initImgBound=20;
InitModule_nonfree ();
Ptr Fdetector (new DenseFeatureDetector (
InitFeatureScale featureScaleLevels, featureScaleMul initXyStep, initImgBound, false));
//Ptr Dextractor=DescriptorExtractor: : create (" SIFT ");
//if (fdetector - & gt; The empty () | | dextractor - & gt; The empty ()) {
//cout & lt; <"FeatureDetector or descExtractor was not created" & lt; //return Mat ();
//}
/* vector Keypoints.
Fdetector - & gt; Detect (img, keypoints);
Mat descriptors.
Dextractor - & gt; Compute (img, the keypoints and descriptors);
CombineDetector. Push_back (descriptors); */
}

CodePudding user response:

See opencv version, you need to be code problems

You put the location of the error code, and the call stack

CodePudding user response:

http://download.csdn.net/index.php/mobile/source/detail/pww71/9513746

CodePudding user response:

2 l error code position at the end of the code after the brackets, all calculations have been counted, view the online code seems to be release stack access conflict problems, but the same code on others' VC2013 (OPENCV 2.49) is also no problem
  • Related