Returns the count of all descriptors stored in the training set.
...
...
@@ -71,7 +71,7 @@ BOWTrainer::cluster
Clusters train descriptors. The vocabulary consists of cluster centers. So, this method returns the vocabulary. In the first variant of the method, train descriptors stored in the object are clustered. In the second variant, input descriptors are clustered.
.. c:function:: Mat BOWTrainer::cluster( const Mat\& descriptors ) const
.. c:function:: Mat BOWTrainer::cluster( const Mat& descriptors ) const
:param descriptors: Descriptors to cluster. Each row of the ``descriptors`` matrix is a descriptor. Descriptors are not added to the inner train descriptor set.
...
...
@@ -81,7 +81,7 @@ BOWTrainer::cluster
BOWKMeansTrainer
----------------
.. c:type:: BOWKMeansTrainer
.. cpp:class:: BOWKMeansTrainer
:ref:`kmeans` -based class to train visual vocabulary using the *bag of visual words* approach ::
...
...
@@ -111,13 +111,15 @@ arguments.
BOWImgDescriptorExtractor
-------------------------
.. c:type:: BOWImgDescriptorExtractor
.. cpp:class:: BOWImgDescriptorExtractor
Class to compute an image descriptor using the ''bag of visual words''. Such a computation consists of the following steps:
#. Compute descriptors for a given image and its keypoints set.
#. Find the nearest visual words from the vocabulary for each keypoint descriptor.
#. Image descriptor is a normalized histogram of vocabulary words encountered in the image. This means that the ``i`` -th bin of the histogram is a frequency of ``i`` -th word of the vocabulary in the given image.??this is not a step ::
#. Compute the bag-of-words image descriptor as is a normalized histogram of vocabulary words encountered in the image. The ``i``-th bin of the histogram is a frequency of ``i``-th word of the vocabulary in the given image.
Here is the class declaration ::
class BOWImgDescriptorExtractor
{
...
...
@@ -144,9 +146,9 @@ Class to compute an image descriptor using the ''bag of visual words''. Such a c
@@ -235,9 +235,7 @@ The function finds the most prominent corners in the image or in the specified i
:func:`cornerHarris` .
#.
Function performs a non-maximum?? suppression (the local maximums in
:math:`3\times 3` neighborhood
are retained).
Function performs a non-maximum suppression (the local maximums in *3 x 3* neighborhood are retained).
#.
The corners with the minimal eigenvalue less than
...
...
@@ -247,10 +245,7 @@ The function finds the most prominent corners in the image or in the specified i
The remaining corners are sorted by the quality measure in the descending order.
#.
Function throws away each corner
:math:`pt_j` if there is a stronger corner
:math:`pt_i` (
:math:`i < j` ) so that the distance between them is less than ``minDistance`` .
Then the function throws away each corner for which there is a stronger corner at a distance less than ``maxDistance``.
The function can be used to initialize a point-based tracker of an object.
...
...
@@ -278,7 +273,7 @@ HoughCircles
:param circles: Output vector of found circles. Each vector is encoded as a 3-element floating-point vector :math:`(x, y, radius)` .
:param method: desc required?? Currently, the only implemented method is ``CV_HOUGH_GRADIENT`` , which is basically *21HT* , described in Yuen90 .
:param method: The detection method to use. Currently, the only implemented method is ``CV_HOUGH_GRADIENT`` , which is basically *21HT* , described in [Yuen90].
:param dp: Inverse ratio of the accumulator resolution to the image resolution. For example, if ``dp=1`` , the accumulator has the same resolution as the input image. If ``dp=2`` , the accumulator has half as big width and height.
...
...
@@ -286,7 +281,7 @@ HoughCircles
:param param1: The first method-specific parameter. In case of ``CV_HOUGH_GRADIENT`` , it is the higher threshold of the two passed to the :func:`Canny` edge detector (the lower one is twice smaller).
:param param2: The second method-specific parameter. In case of ``CV_HOUGH_GRADIENT`` , it is the accumulator threshold at the center of ?? detection stage. The smaller it is, the more false circles may be detected. Circles, corresponding to the larger accumulator values, will be returned first
:param param2: The second method-specific parameter. In case of ``CV_HOUGH_GRADIENT`` , it is the accumulator threshold for the circle centers at the detection stage. The smaller it is, the more false circles may be detected. Circles, corresponding to the larger accumulator values, will be returned first