BOWKMeansTrainer

Objective-C

@interface BOWKMeansTrainer : BOWTrainer

Swift

class BOWKMeansTrainer : BOWTrainer

kmeans -based class to train visual vocabulary using the bag of visual words approach. :

Member of Features2d

Methods

  • The constructor.

     - see: `cv::kmeans`
    

    Declaration

    Objective-C

    - (nonnull instancetype)initWithClusterCount:(int)clusterCount
                                        termcrit:(nonnull TermCriteria *)termcrit
                                        attempts:(int)attempts
                                           flags:(int)flags;

    Swift

    init(clusterCount: Int32, termcrit: TermCriteria, attempts: Int32, flags: Int32)
  • The constructor.

     - see: `cv::kmeans`
    

    Declaration

    Objective-C

    - (nonnull instancetype)initWithClusterCount:(int)clusterCount
                                        termcrit:(nonnull TermCriteria *)termcrit
                                        attempts:(int)attempts;

    Swift

    init(clusterCount: Int32, termcrit: TermCriteria, attempts: Int32)
  • The constructor.

     - see: `cv::kmeans`
    

    Declaration

    Objective-C

    - (nonnull instancetype)initWithClusterCount:(int)clusterCount
                                        termcrit:(nonnull TermCriteria *)termcrit;

    Swift

    init(clusterCount: Int32, termcrit: TermCriteria)
  • The constructor.

     - see: `cv::kmeans`
    

    Declaration

    Objective-C

    - (nonnull instancetype)initWithClusterCount:(int)clusterCount;

    Swift

    init(clusterCount: Int32)
  • Declaration

    Objective-C

    - (nonnull Mat *)cluster:(nonnull Mat *)descriptors;

    Swift

    func cluster(descriptors: Mat) -> Mat
  • Declaration

    Objective-C

    - (Mat*)cluster NS_SWIFT_NAME(cluster());

    Swift

    func cluster() -> Mat