About BBS

CV リファレンス マニュアル

最終変更者: 怡土順一, 最終変更リビジョン: 448, 最終変更日時: 2008-12-24 00:28:23 +0900 (水, 24 12月 2008)


モーション解析と物体追跡(Motion Analysis and Object Tracking)


特徴マッチング(Feature Matching)


CreateFeatureTree

特徴ベクトルのツリーを作成する

CvFeatureTree* cvCreateFeatureTree(CvMat* desc);

desc
d 次元特徴ベクトルの n × d 行列(CV_32FC1 or CV_64FC1).

関数cvCreateFeatureTreeは, 与えられた特徴ベクトルのインデックスに対するバランスk-d木を構築する. desc 行列は,返されるツリーよりも先に解放されてはならない. つまり,特徴ベクトルのコピーは作成されない.


ReleaseFeatureTree

特徴ベクトルのツリーを解放する

void cvReleaseFeatureTree(CvFeatureTree* tr);

tr
開放されるツリーへのポインタ.

関数cvReleaseFeatureTreeは,与えられた k-d木を解放する.


FindFeatures

最適ビン優先(Best-Bin-First)探索を用いて,与えられたベクトルのおおよその k 近傍値を求める

void cvFindFeatures(CvFeatureTree* tr, CvMat* desc,
		    CvMat* results, CvMat* dist, int k=2, int emax=20);

tr
参照ベクトルに対するk-d木インデックスへのポインタ.
desc
(行)ベクトルの m × d 行列.これらのベクトルの近傍値を探索する.
results
一致したベクトルの行インデックス (cvCreateFeatureTreeに引数として渡される行列を参照する) の集合.m × kの行列.k 近傍より遠い場合は,その列には -1 が入る.
dist
k 近傍値までの距離のm × k 行列
k
検出される近傍の数.
emax
探索する葉の最大数.

関数cvFindFeaturesは, descで与えられたそれぞれの(列)ベクトルに対して, (可能性の高い)k 近傍値を,tr の中から見つける. 探索には,最適ビン優先(Best-Bin-First)探索を用いる([Beis97]). 全体の計算量は,最大でO(m*emax*log2(n))である. ここで,nは,ツリー中のベクトル数を表す.


FindFeaturesBoxed

直交領域探索

int cvFindFeaturesBoxed(CvFeatureTree* tr,
			CvMat* bounds_min, CvMat* bounds_max,
			CvMat* results);

tr
参照ベクトルに対するk-d木インデックスへのポインタ.
bounds_min
各次元の最小値を与える 1×d あるいは d×1 のベクトル(CV_32FC1 or CV_64FC1)
bounds_max
各次元の最大値を与える 1×d あるいは d×1 のベクトル(CV_32FC1 or CV_64FC1)
results
出力行インデックス(cvCreateFeatureTreeに引数として渡される行列を参照する) の 1×m あるいは m×1 のベクトル(CV_32SC1)

関数cvFindFeaturesBoxedは,与えられたk-d木上で直交領域探索を行う. つまり,trの中で, bounds_min[i] <= v[i] <= bounds_max[i], 0 <= i < d を満たすベクトルvの集合を求める. ここで,dは,ツリー内のベクトルの次元である. この関数は,求められたベクトル数を返す.

OpenCV-1.0 リファレンス マニュアル
OpenCV-1.1pre リファレンス マニュアル
OpenCVサンプルコード


CV_ASSERT
CV_CALL
CV_CHECK
CV_CMP
CV_ERROR
CV_FUNCNAME
CV_GET_SEQ_ELEM
CV_GRAPH_EDGE_FIELDS
CV_GRAPH_FIELDS
CV_GRAPH_VERTEX_FIELDS
CV_IABS
CV_IMAGE_ELEM
CV_IMAX
CV_IMIN
CV_NODE_HAS_NAME
CV_NODE_IS_COLLECTION
CV_NODE_IS_EMPTY
CV_NODE_IS_FLOW
CV_NODE_IS_INT
CV_NODE_IS_MAP
CV_NODE_IS_REAL
CV_NODE_IS_SEQ
CV_NODE_IS_STRING
CV_NODE_IS_USER
CV_NODE_SEQ_IS_SIMPLE
CV_QUADEDGE2D_FIELDS
CV_RGB
CV_SEQUENCE_FIELDS
CV_SET_FIELDS
CV_SIGN
CV_SUBDIV2D_FIELDS
CV_SUBDIV2D_POINT_FIELDS
CV_SWAP
CV_TREE_NODE_FIELDS
CV_TURN_ON_IPL_COMPATIBILITY
EXIT
MAX
MIN
OPENCV_ASSERT
OPENCV_CALL
OPENCV_ERRCHK
OPENCV_ERROR
__BEGIN__
__END__

CvANN_MLP
CvANN_MLP::create
CvANN_MLP::train
CvANN_MLP_TrainParams
CvArr
CvAttrList
CvBoost
CvBoost::get_weak_predictors
CvBoost::predict
CvBoost::prune
CvBoost::train
CvBoostParams
CvBoostTree
CvBox2D
CvCapture
CvConDensation
CvConnectedComp
CvConvexityDefect
CvDTree
CvDTree::predict
CvDTree::train
CvDTreeNode
CvDTreeParams
CvDTreeSplit
CvDTreeTrainData
CvEM
CvEM::train
CvEMParams
CvFileNode
CvFileStorage
CvGraph
CvGraphScanner
CvHMM
CvHaarClassifier
CvHaarClassifierCascade
CvHaarFeature
CvHaarStageClassifier
CvHistogram
CvImgObsInfo
CvKNearest
CvKNearest::find_nearest
CvKNearest_train
CvKalman
CvMat
CvMatND
CvMemBlock
CvMemStorage
CvMemStoragePos
CvNormalBayesClassifier
CvNormalBayesClassifier::predict
CvNormalBayesClassifier::train
CvPoint
CvPoint2D32f
CvPoint2D64f
CvPoint3D32f
CvPoint3D64f
CvQuadEdge2D
CvRTParams
CvRTrees
CvRTrees::get_proximity
CvRTrees::get_var_importance
CvRTrees::predict
CvRTrees::train
CvRect
CvSVM
CvSVM::get_default_grid
CvSVM::get_params
CvSVM::get_support_vector
CvSVM::train
CvSVM::train_auto
CvSVMParams
CvScalar
CvSeq
CvSeqBlock
CvSet
CvSize
CvSize2D32f
CvSlice
CvSparseMat
CvStatModel
CvStatModel::CvStatModel
CvStatModel::CvStatModel(data)
CvStatModel::clear
CvStatModel::load
CvStatModel::predict
CvStatModel::read
CvStatModel::save
CvStatModel::train
CvStatModel::write
CvStatModel::~CvStatModel
CvStereoBMState
CvStereoGCState
CvSubdiv2D
CvSubdiv2DPoint
CvTermCriteria
CvTreeNodeIterator
CvTypeInfo
IplImage
RTreesOOBerror

cv2DRotationMatrix
cv3dTrackerCalibrateCameras
cv3dTrackerLocateObjects
cvAbs
cvAbsDiff
cvAbsDiffS
cvAcc
cvAdaptiveThreshold
cvAdd
cvAddS
cvAddWeighted
cvAlloc
cvAnd
cvAndS
cvApproxChains
cvApproxPoly
cvArcLength
cvAvg
cvAvgSdv
cvBackProjectPCA
cvBoundingRect
cvBoxPoints
cvCalcBackProject
cvCalcBackProjectPatch
cvCalcCovarMatrix
cvCalcCovarMatrixEx
cvCalcDecompCoeff
cvCalcEMD2
cvCalcEigenObjects
cvCalcGlobalOrientation
cvCalcHist
cvCalcImageHomography
cvCalcMotionGradient
cvCalcOpticalFlowBM
cvCalcOpticalFlowHS
cvCalcOpticalFlowLK
cvCalcOpticalFlowPyrLK
cvCalcPCA
cvCalcPGH
cvCalcProbDensity
cvCalcSubdivVoronoi2D
cvCalibrateCamera2
cvCalibrationMatrixValues
cvCamShift
cvCanny
cvCartToPolar
cvCbrt
cvCheckArr
cvCheckArray
cvCheckContourConvexity
cvCircle
cvClearGraph
cvClearHist
cvClearMemStorage
cvClearND
cvClearSeq
cvClearSet
cvClearSubdivVoronoi2D
cvClipLine
cvClone
cvCloneGraph
cvCloneImage
cvCloneMat
cvCloneMatND
cvCloneSeq
cvCloneSparseMat
cvCmp
cvCmpS
cvCompareHist
cvComputeCorrespondEpilines
cvConDensInitSampleSet
cvConDensUpdateByTime
cvContourArea
cvContourFromContourTree
cvConvert
cvConvertImage
cvConvertPointsHomogeneous
cvConvertScale
cvConvertScaleAbs
cvConvexHull2
cvConvexityDefects
cvCopy
cvCopyHist
cvCopyMakeBorder
cvCornerEigenValsAndVecs
cvCornerHarris
cvCornerMinEigenVal
cvCountNonZero
cvCreate2DHMM
cvCreateCameraCapture
cvCreateChildMemStorage
cvCreateConDensation
cvCreateContourTree
cvCreateData
cvCreateFeatureTree
cvCreateFileCapture
cvCreateGraph
cvCreateGraphScanner
cvCreateHist
cvCreateImage
cvCreateImageHeader
cvCreateKalman
cvCreateMat
cvCreateMatHeader
cvCreateMatND
cvCreateMatNDHeader
cvCreateMemStorage
cvCreateObsInfo
cvCreatePOSITObject
cvCreateSeq
cvCreateSet
cvCreateSparseMat
cvCreateStereoBMState
cvCreateStereoGCState
cvCreateStructuringElementEx
cvCreateSubdivDelaunay2D
cvCreateTrackbar
cvCreateVideoWriter
cvCrossProduct
cvCvtColor
cvCvtPixToPlane
cvCvtPlaneToPix
cvCvtScale
cvCvtScaleAbs
cvCvtSeqToArray
cvDCT
cvDFT
cvDecRefData
cvDeleteMoire
cvDestroyAllWindows
cvDestroyWindow
cvDet
cvDilate
cvDistTransform
cvDiv
cvDotProduct
cvDrawChessBoardCorners
cvDrawContours
cvDynamicCorrespondMulti
cvEViterbi
cvEigenDecomposite
cvEigenProjection
cvEigenVV
cvEllipse
cvEllipse2Poly
cvEllipseBox
cvEndFindContours
cvEndWriteSeq
cvEndWriteStruct
cvEqualizeHist
cvErode
cvError
cvErrorStr
cvEstimateHMMStateParams
cvEstimateObsProb
cvEstimateTransProb
cvExp
cvExtractSURF
cvFastArctan
cvFillConvexPoly
cvFillPoly
cvFilter2D
cvFindChessboardCorners
cvFindContours
cvFindCornerSubPix
cvFindExtrinsicCameraParams2
cvFindFeatures
cvFindFeaturesBoxed
cvFindFundamentalMat
cvFindGraphEdge
cvFindGraphEdgeByPtr
cvFindHomography
cvFindNearestPoint2D
cvFindNextContour
cvFindRuns
cvFindStereoCorrespondence
cvFindStereoCorrespondenceBM
cvFindStereoCorrespondenceGC
cvFindType
cvFirstType
cvFitEllipse2
cvFitLine2D
cvFlip
cvFloodFill
cvFlushSeqWriter
cvFree
cvGEMM
cvGet1D
cvGet2D
cvGet3D
cvGetAffineTransform
cvGetCaptureProperty
cvGetCentralMoment
cvGetCol
cvGetCols
cvGetDiag
cvGetDims
cvGetElemType
cvGetErrMode
cvGetErrStatus
cvGetFileNode
cvGetFileNodeByName
cvGetFileNodeName
cvGetGraphVtx
cvGetHashedKey
cvGetHistValue_1D
cvGetHistValue_2D
cvGetHistValue_3D
cvGetHistValue_nD
cvGetHuMoments
cvGetImage
cvGetImageCOI
cvGetImageROI
cvGetMat
cvGetMinMaxHistValue
cvGetModuleInfo
cvGetND
cvGetNextSparseNode
cvGetNormalizedCentralMoment
cvGetNumThreads
cvGetOptimalDFTSize
cvGetPerspectiveTransform
cvGetQuadrangleSubPix
cvGetRawData
cvGetReal1D
cvGetReal2D
cvGetReal3D
cvGetRealND
cvGetRectSubPix
cvGetRootFileNode
cvGetRow
cvGetRows
cvGetSeqElem
cvGetSeqReaderPos
cvGetSetElem
cvGetSize
cvGetSpatialMoment
cvGetSubRect
cvGetTextSize
cvGetThreadNum
cvGetTickCount
cvGetTickFrequency
cvGetTrackbarPos
cvGetWindowHandle
cvGetWindowName
cvGoodFeaturesToTrack
cvGrabFrame
cvGraphAddEdge
cvGraphAddEdgeByPtr
cvGraphAddVtx
cvGraphEdgeIdx
cvGraphFindEdge
cvGraphFindEdgeByPtr
cvGraphRemoveEdge
cvGraphRemoveEdgeByPtr
cvGraphRemoveVtx
cvGraphRemoveVtxByPtr
cvGraphVtxDegree
cvGraphVtxDegreeByPtr
cvGraphVtxIdx
cvGuiBoxReport
cvHaarDetectObjects
cvHoughCircles
cvHoughLines2
cvImgToObs_DCT
cvInRange
cvInRangeS
cvIncRefData
cvInitFont
cvInitImageHeader
cvInitLineIterator
cvInitMatHeader
cvInitMatNDHeader
cvInitMixSegm
cvInitSparseMatIterator
cvInitSystem
cvInitTreeNodeIterator
cvInitUndistortMap
cvInitUndistortRectifyMap
cvInpaint
cvInsertNodeIntoTree
cvIntegral
cvInv
cvInvSqrt
cvInvert
cvIsInf
cvIsNaN
cvKMeans2
cvKalmanCorrect
cvKalmanPredict
cvKalmanUpdateByMeasurement
cvKalmanUpdateByTime
cvLUT
cvLaplace
cvLine
cvLoad
cvLoadHaarClassifierCascade
cvLoadImage
cvLog
cvLogPolar
cvMahalanobis
cvMakeAlphaScanlines
cvMakeHistHeaderForArray
cvMakeScanlines
cvMakeSeqHeaderForArray
cvMat
cvMatMul
cvMatMulAdd
cvMatchContourTrees
cvMatchShapes
cvMatchTemplate
cvMax
cvMaxRect
cvMaxS
cvMeanShift
cvMemStorageAlloc
cvMemStorageAllocString
cvMerge
cvMin
cvMinAreaRect2
cvMinEnclosingCircle
cvMinMaxLoc
cvMinS
cvMirror
cvMixChannels
cvMixSegmL2
cvMoments
cvMorphEpilinesMulti
cvMorphologyEx
cvMoveWindow
cvMul
cvMulAddS
cvMulSpectrums
cvMulTransposed
cvMultiplyAcc
cvNamedWindow
cvNextGraphItem
cvNextTreeNode
cvNorm
cvNormalize
cvNormalizeHist
cvNot
cvNulDevReport
cvOpenFileStorage
cvOr
cvOrS
cvPOSIT
cvPerspectiveTransform
cvPointPolygonTest
cvPointSeqFromMat
cvPolarToCart
cvPolyLine
cvPostWarpImage
cvPow
cvPreCornerDetect
cvPreWarpImage
cvPrevTreeNode
cvProjectPCA
cvProjectPoints2
cvPtr1D
cvPtr2D
cvPtr3D
cvPtrND
cvPutText
cvPyrDown
cvPyrMeanShiftFiltering
cvPyrSegmentation
cvPyrUp
cvQueryFrame
cvQueryHistValue_1D
cvQueryHistValue_2D
cvQueryHistValue_3D
cvQueryHistValue_nD
cvRNG
cvRandArr
cvRandInt
cvRandReal
cvRandShuffle
cvRange
cvRead
cvReadByName
cvReadChainPoint
cvReadInt
cvReadIntByName
cvReadRawData
cvReadRawDataSlice
cvReadReal
cvReadRealByName
cvReadString
cvReadStringByName
cvRectangle
cvRedirectError
cvReduce
cvRegisterModule
cvRegisterType
cvRelease
cvRelease2DHMM
cvReleaseCapture
cvReleaseConDensation
cvReleaseData
cvReleaseFeatureTree
cvReleaseFileStorage
cvReleaseGraphScanner
cvReleaseHaarClassifierCascade
cvReleaseHist
cvReleaseImage
cvReleaseImageHeader
cvReleaseKalman
cvReleaseMat
cvReleaseMatND
cvReleaseMemStorage
cvReleaseObsInfo
cvReleasePOSITObject
cvReleaseSparseMat
cvReleaseStereoBMState
cvReleaseStereoGCState
cvReleaseStructuringElement
cvReleaseVideoWriter
cvRemap
cvRemoveNodeFromTree
cvRepeat
cvReprojectImageTo3D
cvResetImageROI
cvReshape
cvReshapeMatND
cvReshapeND
cvResize
cvResizeWindow
cvRestoreMemStoragePos
cvRetrieveFrame
cvRodrigues2
cvRound
cvRunHaarClassifierCascade
cvRunningAvg
cvSVBkSb
cvSVD
cvSampleLine
cvSave
cvSaveImage
cvSaveMemStoragePos
cvScale
cvScaleAdd
cvSegmentMotion
cvSeqElemIdx
cvSeqInsert
cvSeqInsertSlice
cvSeqInvert
cvSeqPartition
cvSeqPop
cvSeqPopFront
cvSeqPopMulti
cvSeqPush
cvSeqPushFront
cvSeqPushMulti
cvSeqRemove
cvSeqRemoveSlice
cvSeqSearch
cvSeqSlice
cvSeqSort
cvSet
cvSet1D
cvSet2D
cvSet3D
cvSetAdd
cvSetCaptureProperty
cvSetData
cvSetErrMode
cvSetErrStatus
cvSetHistBinRanges
cvSetIPLAllocators
cvSetIdentity
cvSetImageCOI
cvSetImageROI
cvSetImagesForHaarClassifierCascade
cvSetMemoryManager
cvSetMouseCallback
cvSetND
cvSetNew
cvSetNumThreads
cvSetReal1D
cvSetReal2D
cvSetReal3D
cvSetRealND
cvSetRemove
cvSetRemoveByPtr
cvSetSeqBlockSize
cvSetSeqReaderPos
cvSetTrackbarPos
cvSetZero
cvShowImage
cvSmooth
cvSnakeImage
cvSobel
cvSolveCubic
cvSolvePoly
cvSplit
cvSqrt
cvSquareAcc
cvStartAppendToSeq
cvStartFindContours
cvStartNextStream
cvStartReadChainPoints
cvStartReadRawData
cvStartReadSeq
cvStartWriteSeq
cvStartWriteStruct
cvStdErrReport
cvStereoCalibrate
cvStereoRectify
cvStereoRectifyUncalibrated
cvSub
cvSubRS
cvSubS
cvSubdiv2DEdgeDst
cvSubdiv2DEdgeOrg
cvSubdiv2DGetEdge
cvSubdiv2DLocate
cvSubdiv2DNextEdge
cvSubdiv2DRotateEdge
cvSubdivDelaunay2DInsert
cvSubstituteContour
cvSum
cvT
cvThreshHist
cvThreshold
cvTrace
cvTransform
cvTranspose
cvTreeToNodeSeq
cvTypeOf
cvUndistort2
cvUndistortPoints
cvUniformImgSegm
cvUnregisterType
cvUpdateMotionHistory
cvUseOptimized
cvWaitKey
cvWarpAffine
cvWarpPerspective
cvWarpPerspectiveQMatrix
cvWatershed
cvWrite
cvWriteComment
cvWriteFileNode
cvWriteFrame
cvWriteInt
cvWriteRawData
cvWriteReal
cvWriteString
cvXor
cvXorS
cvZero
cvmGet
cvmSet
error_handling_sample