Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Long exit from program (long runtime exit). after save SVM opencv it is take long time to exit program

I used SVM in OpenCV 3.x and after save SVM, the program takes long time to exit:

Ptr<TrainData> td1 = TrainData::create(trainingDataMat, ROW_SAMPLE, labelsMat);
svm->trainAuto(td1);
cout << " save svm" << endl;
svm->save(fileSVM);

I used F10 to find problem and I found that

 #ifndef _CRT_APP
      exit(mainret);

may take this problem. How can solve this problem?

Thanks in advance.