Definition at line 391 of file HarrisLaplaceDetector.h. References BoostImage(), Impala::Core::Array::Array2dTem< StorT, elemSize, ArithT >::CH(), Impala::Core::Array::Array2dTem< StorT, elemSize, ArithT >::CW(), harrisCornerDetector(), ILOG_DEBUG, ILOG_INFO, laplacianScaleSelection(), Impala::Core::Table::Table::Size(), Impala::Core::Table::SortOnColumn5(), and Impala::Timer::SplitTimeStr(). Referenced by Impala::Core::Feature::InterestPointFeature::ApplyDetector(). 00392 { 00393 Timer timer; 00394 PointDescriptorTable* output = new PointDescriptorTable(); 00395 00396 // boost image 00397 Array2dVec3Real64* imBoosted = 0; 00398 BoostImage(imBoosted, input, 0.065, 0.850, 0.524); 00399 00402 //MulVal(imIntensity, imIntensity, 1 / 255.0); 00403 00404 // Harris corner detection 00405 MyPointList centroids; 00406 Real64 sigmaZero = 0.75; 00407 Real64 borderIgnoreSize = 4.0; 00408 for(int sigmaCounter = 1; sigmaCounter <= 8; sigmaCounter++) 00409 { 00410 Real64 sigmaN = pow(sqrt(Real64(2)), sigmaCounter) * sigmaZero; 00411 MyPointList pointList; 00412 harrisCornerDetector(pointList, imBoosted, sigmaN, harrisK, harrisThreshold); 00413 for(MyPointList::iterator iter = pointList.begin(); iter != pointList.end(); iter++) 00414 { 00415 MyPoint* point(*iter); 00416 00417 point->mDetectionScale = sigmaN; 00418 //ILOG_DEBUG(" " << point->mX << " " << point->mY << " " << point->mCornerness << " " << point->mDetectionScale); 00419 if((point->mX < borderIgnoreSize) || 00420 (point->mY < borderIgnoreSize) || 00421 (point->mX >= imBoosted->CW() - borderIgnoreSize) || 00422 (point->mY >= imBoosted->CH() - borderIgnoreSize)) 00423 { 00424 ILOG_DEBUG(" " << point->mX << " " << point->mY << " BORDER CLOSENESS REJECT"); 00425 continue; 00426 } 00427 centroids.push_back(point); 00428 } 00429 ILOG_DEBUG(sigmaN << " " << pointList.size()); 00430 } 00431 ILOG_INFO("Harris corner detector found " << centroids.size() << " points"); 00432 ILOG_DEBUG("[Timing2] HarrisCornerDetector " << timer.SplitTimeStr()); 00433 00434 // Laplacian scale selection 00435 laplacianScaleSelection(output, imBoosted, centroids, laplaceThreshold); 00436 00437 delete imBoosted; 00438 00439 ILOG_INFO("Laplacian scale selection left " << output->Size() << " points"); 00440 ILOG_DEBUG("[Timing2] LaplacianScaleSelection" << timer.SplitTimeStr()); 00441 00442 // now sort the points by cornerness 00443 SortOnColumn5(output, false); 00444 return output; 00445 }
Here is the call graph for this function:
|