Main MRPT website > C++ reference for MRPT 1.5.7
Classes | Typedefs | Functions
Feature detection, descriptors and matching

Detailed Description

Collaboration diagram for Feature detection, descriptors and matching:

Classes

class  mrpt::vision::CFeature
 A generic 2D feature from an image, extracted with CFeatureExtraction Each feature may have one or more descriptors (see descriptors), in addition to an image patch. More...
 
class  mrpt::vision::CFeatureList
 A list of visual features, to be used as output by detectors, as input/output by trackers, etc. More...
 
class  mrpt::vision::CMatchedFeatureList
 A list of features. More...
 
class  mrpt::vision::CFeatureExtraction
 The central class from which images can be analyzed in search of different kinds of interest points and descriptors computed for them. More...
 
struct  mrpt::vision::TSimpleFeature_templ< PIXEL_COORD_TYPE >
 A simple structure for representing one image feature (without descriptor nor patch) - This is the template which allows you to select if pixels are represented as integers or floats. More...
 
struct  mrpt::vision::TSimpleFeatureTraits< FEATURE >
 
struct  mrpt::vision::TSimpleFeatureTraits< TSimpleFeature >
 
struct  mrpt::vision::TSimpleFeatureTraits< TSimpleFeaturef >
 
struct  mrpt::vision::TSimpleFeatureList_templ< FEATURE >
 A list of image features using the structure TSimpleFeature for each feature - capable of KD-tree computations Users normally use directly the typedef's: TSimpleFeatureList & TSimpleFeaturefList. More...
 
struct  mrpt::vision::KeypointResponseSorter< FEATURE_LIST >
 A helper struct to sort keypoints by their response: It can be used with these types: More...
 
class  mrpt::vision::CFeatureListKDTree< FEAT >
 Helper class: KD-tree search class for vector<KeyPoint>: Call mark_as_outdated() to force rebuilding the kd-tree after modifying the linked feature list. More...
 

Typedefs

typedef TSimpleFeature_templ< mrpt::utils::TPixelCoordmrpt::vision::TSimpleFeature
 A simple structure for representing one image feature (without descriptor nor patch). More...
 
typedef TSimpleFeature_templ< mrpt::utils::TPixelCoordfmrpt::vision::TSimpleFeaturef
 A version of TSimpleFeature with subpixel precision. More...
 
typedef TSimpleFeatureList_templ< TSimpleFeaturemrpt::vision::TSimpleFeatureList
 A list of image features using the structure TSimpleFeature for each feature - capable of KD-tree computations. More...
 
typedef TSimpleFeatureList_templ< TSimpleFeaturefmrpt::vision::TSimpleFeaturefList
 A list of image features using the structure TSimpleFeaturef for each feature - capable of KD-tree computations. More...
 

Functions

::mrpt::utils::CStreammrpt::vision::operator>> (mrpt::utils::CStream &in, CFeaturePtr &pObj)
 
template<class DESCRIPTOR_KDTREE >
size_t mrpt::vision::find_descriptor_pairings (std::vector< vector_size_t > *pairings_1_to_multi_2, std::vector< std::pair< size_t, size_t > > *pairings_1_to_2, const CFeatureList &feats_img1, const DESCRIPTOR_KDTREE &feats_img2_kdtree, const mrpt::vision::TDescriptorType descriptor=descSIFT, const size_t max_neighbors=4, const double max_relative_distance=1.2, const typename DESCRIPTOR_KDTREE::kdtree_t::DistanceType max_distance=std::numeric_limits< typename DESCRIPTOR_KDTREE::kdtree_t::DistanceType >::max())
 Search for pairings between two sets of visual descriptors (for now, only SURF and SIFT features are considered). More...
 

Static methods with low-level detector functionality

static void mrpt::vision::CFeatureExtraction::detectFeatures_SSE2_FASTER9 (const mrpt::utils::CImage &img, TSimpleFeatureList &corners, const int threshold=20, bool append_to_list=false, uint8_t octave=0, std::vector< size_t > *out_feats_index_by_row=NULL)
 A SSE2-optimized implementation of FASTER-9 (requires img to be grayscale). More...
 
static void mrpt::vision::CFeatureExtraction::detectFeatures_SSE2_FASTER10 (const mrpt::utils::CImage &img, TSimpleFeatureList &corners, const int threshold=20, bool append_to_list=false, uint8_t octave=0, std::vector< size_t > *out_feats_index_by_row=NULL)
 Just like detectFeatures_SSE2_FASTER9() for another version of the detector. More...
 
static void mrpt::vision::CFeatureExtraction::detectFeatures_SSE2_FASTER12 (const mrpt::utils::CImage &img, TSimpleFeatureList &corners, const int threshold=20, bool append_to_list=false, uint8_t octave=0, std::vector< size_t > *out_feats_index_by_row=NULL)
 Just like detectFeatures_SSE2_FASTER9() for another version of the detector. More...
 

Typedef Documentation

◆ TSimpleFeature

A simple structure for representing one image feature (without descriptor nor patch).

See also
TSimpleFeaturef, CFeature, TSimpleFeatureList

Definition at line 68 of file TSimpleFeature.h.

◆ TSimpleFeaturef

A version of TSimpleFeature with subpixel precision.

Definition at line 71 of file TSimpleFeature.h.

◆ TSimpleFeaturefList

A list of image features using the structure TSimpleFeaturef for each feature - capable of KD-tree computations.

Definition at line 206 of file TSimpleFeature.h.

◆ TSimpleFeatureList

A list of image features using the structure TSimpleFeature for each feature - capable of KD-tree computations.

Definition at line 203 of file TSimpleFeature.h.

Function Documentation

◆ detectFeatures_SSE2_FASTER10()

void CFeatureExtraction::detectFeatures_SSE2_FASTER10 ( const mrpt::utils::CImage img,
TSimpleFeatureList corners,
const int  threshold = 20,
bool  append_to_list = false,
uint8_t  octave = 0,
std::vector< size_t > *  out_feats_index_by_row = NULL 
)
static

◆ detectFeatures_SSE2_FASTER12()

void CFeatureExtraction::detectFeatures_SSE2_FASTER12 ( const mrpt::utils::CImage img,
TSimpleFeatureList corners,
const int  threshold = 20,
bool  append_to_list = false,
uint8_t  octave = 0,
std::vector< size_t > *  out_feats_index_by_row = NULL 
)
static

◆ detectFeatures_SSE2_FASTER9()

void CFeatureExtraction::detectFeatures_SSE2_FASTER9 ( const mrpt::utils::CImage img,
TSimpleFeatureList corners,
const int  threshold = 20,
bool  append_to_list = false,
uint8_t  octave = 0,
std::vector< size_t > *  out_feats_index_by_row = NULL 
)
static

A SSE2-optimized implementation of FASTER-9 (requires img to be grayscale).

If SSE2 is not available, it gratefully falls back to a non-optimized version.

Only the pt.{x,y} fields are filled out for each feature: the rest of fields are left uninitialized and their content is undefined. Note that (x,y) are already scaled to the 0-level image coordinates if octave>0, by means of:

pt.x = detected.x << octave;
pt.y = detected.y << octave;

If append_to_list is true, the corners list is not cleared before adding the newly detected feats.

If a valid pointer is provided for out_feats_index_by_row, upon return you will find a vector with as many entries as rows in the image (the real number of rows, disregarding the value of octave). The number in each entry is the 0-based index (in corners) of the first feature that falls in that line of the image. This index can be used to fasten looking for correspondences.

Definition at line 30 of file CFeatureExtraction_FASTER.cpp.

References ASSERTDEB_, mrpt::vision::TSimpleFeatureList_templ< FEATURE >::clear(), fast_corner_detect_9(), and THROW_EXCEPTION.

◆ find_descriptor_pairings()

template<class DESCRIPTOR_KDTREE >
size_t mrpt::vision::find_descriptor_pairings ( std::vector< vector_size_t > *  pairings_1_to_multi_2,
std::vector< std::pair< size_t, size_t > > *  pairings_1_to_2,
const CFeatureList feats_img1,
const DESCRIPTOR_KDTREE &  feats_img2_kdtree,
const mrpt::vision::TDescriptorType  descriptor = descSIFT,
const size_t  max_neighbors = 4,
const double  max_relative_distance = 1.2,
const typename DESCRIPTOR_KDTREE::kdtree_t::DistanceType  max_distance = std::numeric_limits<typename DESCRIPTOR_KDTREE::kdtree_t::DistanceType>::max() 
)

Search for pairings between two sets of visual descriptors (for now, only SURF and SIFT features are considered).

Pairings are returned in one of two formats (or both of them simultaneously), depending on the non-NULL output containers present in the call.

CFeatureList feats1, feats2;
// Populate feature lists [...]
// Create kd-tree for SIFT features of "feats2":
TSIFTDescriptorsKDTreeIndex<double> feats2_kdtree(feats2);
// Search correspondences:
std::vector<vector_size_t> pairings_1_to_multi_2;
std::vector<std::pair<size_t,size_t> > pairings_1_to_2;
&pairings_1_to_multi_2, // Can be set to NULL if not needed
&pairings_1_to_2, // Can be set to NULL if not needed
feats1, feats2_kdtree, // The two sets of features
mrpt::vision::descSIFT // Select descriptor to use
// [further optional params]
);
See also
TSIFTDescriptorsKDTreeIndex, TSURFDescriptorsKDTreeIndex

Definition at line 49 of file descriptor_pairing.h.

References ASSERT_, ASSERT_ABOVEEQ_, ASSERTMSG_, mrpt::vision::descSIFT, mrpt::vision::descSURF, min, MRPT_END, MRPT_START, mrpt::vision::CFeature::TDescriptors::SIFT, mrpt::vision::CFeatureList::size(), mrpt::vision::CFeature::TDescriptors::SURF, and THROW_EXCEPTION.

◆ operator>>()

::mrpt::utils::CStream& mrpt::vision::operator>> ( mrpt::utils::CStream in,
CFeaturePtr &  pObj 
)



Page generated by Doxygen 1.8.14 for MRPT 1.5.7 Git: 5902e14cc Wed Apr 24 15:04:01 2019 +0200 at lun oct 28 01:39:17 CET 2019