OpenCV for Unity 2.6.4
Enox Software / Please refer to OpenCV official document ( http://docs.opencv.org/4.10.0/index.html ) for the details of the argument of the method.
Loading...
Searching...
No Matches
OpenCVForUnity.Features2dModule.BOWTrainer Class Reference

Abstract base class for training the bag of visual words vocabulary from a set of descriptors. More...

Public Member Functions

void add (Mat descriptors)
 Adds descriptors to a training set.
 
void clear ()
 
virtual Mat cluster ()
 
virtual Mat cluster (Mat descriptors)
 Clusters train descriptors.
 
int descriptorsCount ()
 Returns the count of all descriptors stored in the training set.
 
List< MatgetDescriptors ()
 Returns a training set of descriptors.
 
IntPtr getNativeObjAddr ()
 
- Public Member Functions inherited from OpenCVForUnity.DisposableObject
void Dispose ()
 
void ThrowIfDisposed ()
 

Static Public Member Functions

static BOWTrainer __fromPtr__ (IntPtr addr)
 
- Static Public Member Functions inherited from OpenCVForUnity.DisposableObject
static IntPtr ThrowIfNullIntPtr (IntPtr ptr)
 

Protected Member Functions

override void Dispose (bool disposing)
 
- Protected Member Functions inherited from OpenCVForUnity.DisposableOpenCVObject
 DisposableOpenCVObject ()
 
 DisposableOpenCVObject (bool isEnabledDispose)
 
 DisposableOpenCVObject (IntPtr ptr)
 
 DisposableOpenCVObject (IntPtr ptr, bool isEnabledDispose)
 
override void Dispose (bool disposing)
 
- Protected Member Functions inherited from OpenCVForUnity.DisposableObject
 DisposableObject ()
 
 DisposableObject (bool isEnabledDispose)
 

Additional Inherited Members

- Package Attributes inherited from OpenCVForUnity.DisposableOpenCVObject
- Properties inherited from OpenCVForUnity.DisposableObject
bool IsDisposed [get, protected set]
 
bool IsEnabledDispose [get, set]
 

Detailed Description

Abstract base class for training the bag of visual words vocabulary from a set of descriptors.

For details, see, for example, Visual Categorization with Bags of Keypoints by Gabriella Csurka, Christopher R. Dance, Lixin Fan, Jutta Willamowski, Cedric Bray, 2004. :

Member Function Documentation

◆ __fromPtr__()

static BOWTrainer OpenCVForUnity.Features2dModule.BOWTrainer.__fromPtr__ ( IntPtr addr)
static

◆ add()

void OpenCVForUnity.Features2dModule.BOWTrainer.add ( Mat descriptors)

Adds descriptors to a training set.

Parameters
descriptorsDescriptors to add to a training set. Each row of the descriptors matrix is a descriptor.

The training set is clustered using clustermethod to construct the vocabulary.

◆ clear()

void OpenCVForUnity.Features2dModule.BOWTrainer.clear ( )

◆ cluster() [1/2]

virtual Mat OpenCVForUnity.Features2dModule.BOWTrainer.cluster ( )
virtual

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Reimplemented in OpenCVForUnity.Features2dModule.BOWKMeansTrainer.

◆ cluster() [2/2]

virtual Mat OpenCVForUnity.Features2dModule.BOWTrainer.cluster ( Mat descriptors)
virtual

Clusters train descriptors.

Parameters
descriptorsDescriptors to cluster. Each row of the descriptors matrix is a descriptor. Descriptors are not added to the inner train descriptor set.

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.

Reimplemented in OpenCVForUnity.Features2dModule.BOWKMeansTrainer.

◆ descriptorsCount()

int OpenCVForUnity.Features2dModule.BOWTrainer.descriptorsCount ( )

Returns the count of all descriptors stored in the training set.

◆ Dispose()

override void OpenCVForUnity.Features2dModule.BOWTrainer.Dispose ( bool disposing)
protectedvirtual

Reimplemented from OpenCVForUnity.DisposableObject.

◆ getDescriptors()

List< Mat > OpenCVForUnity.Features2dModule.BOWTrainer.getDescriptors ( )

Returns a training set of descriptors.

◆ getNativeObjAddr()

IntPtr OpenCVForUnity.Features2dModule.BOWTrainer.getNativeObjAddr ( )

The documentation for this class was generated from the following file: