VGPyramidMaker Class Reference

#include <vg-pyramid-maker.h>

Inheritance diagram for VGPyramidMaker:

PyramidMaker GlobalVGPyramidMaker InputSpecificVGPyramidMaker List of all members.

Detailed Description

Abstract interface for vocabulary-guided pyramid makers.

The vocabulary-guided pyramid makers here use the output of a hierarchical clustering algorithm to generate pyramids.


Public Member Functions

 VGPyramidMaker (const HierarchicalClusterer &c, const DistanceComputer &distance_computer)
virtual MultiResolutionHistogramMakePyramid (const PointSet &point_set)=0
 Turn a single PointSet into a MultiResolutionHistogram.
vector< MultiResolutionHistogram * > MakePyramids (const PointSetList &psl)
 Turn a list of PointSets into a bunch of MultiResolutionHistograms.

Protected Member Functions

pair< LargeIndex, vector<
double > > 
GetMembershipPath (const Feature &f)
 For a new feature, find which bin it would be placed in according to the HierarchicalClusterer.

Protected Attributes

const HierarchicalClustererclusterer_
const PointSetListcenters_
 The centers extracted from clusterer_.
const DistanceComputerdistance_computer_


Constructor & Destructor Documentation

VGPyramidMaker ( const HierarchicalClusterer c,
const DistanceComputer distance_computer 
)

Requires a HierarchicalCluster which has already been Preprocess()'d (or ReadFromStream()), and a DistanceComputer which computes the same distances that were used to generate the HierarchicalClusterer's data.


Member Function Documentation

virtual MultiResolutionHistogram* MakePyramid ( const PointSet point_set  )  [pure virtual]

Turn a single PointSet into a MultiResolutionHistogram.

This function allocates memory on its own. It is up to the caller to free it.

Implements PyramidMaker.

Implemented in GlobalVGPyramidMaker, and InputSpecificVGPyramidMaker.

pair< LargeIndex, vector< double > > GetMembershipPath ( const Feature f  )  [protected]

For a new feature, find which bin it would be placed in according to the HierarchicalClusterer.

The LargeIndex returned is the same size as the number of levels in the tree. Each element of the LargeIndex tells you which element in centers_ that point belongs to. That is, if the returned LargeIndex is [0 3 9], then centers_[0][0] is the root bin, centers_[1][3] is the center corresponding to this point at level 1, centers_[2][9] is the center corresponding to this point at level 2.

The returned vector of doubles gives the distance to the corresponding center at each level, according to distance_computer_.

Reimplemented in GlobalVGPyramidMaker.

vector< MultiResolutionHistogram * > MakePyramids ( const PointSetList psl  )  [inherited]

Turn a list of PointSets into a bunch of MultiResolutionHistograms.

It is up to the caller to free the memory.


Member Data Documentation

const HierarchicalClusterer& clusterer_ [protected]

const PointSetList& centers_ [protected]

The centers extracted from clusterer_.

const DistanceComputer& distance_computer_ [protected]


The documentation for this class was generated from the following files:
Generated on Wed May 2 11:17:13 2007 for libpmk by  doxygen 1.5.1