This interface provide functionalities of the image features, which is used for feature extraction from image in machine learning technology.
More...
This interface provide functionalities of the image features, which is used for feature extraction from image in machine learning technology.
You should firstly create the image feature with specified type via Create(), then adjust its parameters via ILParameterized interface.
Currently, we support following features:
Feature | Usage and Parameters |
ORB | Oriented FAST and Rotated BRIEF
Parameter Name | Usage | Type | Range | Default |
"count" | Count of vocabulary in Bag-of-Words | Integer | 8 ~ 2048 | 64 |
"patch size" | Size of each patch | Integer | 4 ~ 256 | 32 |
"scale factor" | Scale factor for the pyramid | Double | 1 ~ 2 | 1.2 |
"scale-down level" | Total level count of the scale-down pyramid | Integer | > 0 | 5 |
"random point pair count" | The number of points that produce each element of ORB | Integer | 2 ~ 4 | 2 |
|
HOG | Histogram of Oriented Gradients
Parameter Name | Usage | Type | Range | Default |
"cell size" | Size of a cell that build the histogram | Size | \( 2 \times 2 \) ~ \( 128 \times 128 \)
must be \( 2^x \) | \( 4 \times 4 \) |
"bin size" | Bins of histogram, should be factor of 360 or 180, depending on whether gradient is signed | Integer | 1 ~ 60 | 9 |
"cell in block" | Count of cells in a block | Size | \( 1 \times 1 \) ~ \( 64 \times 64 \) | \( 2 \times 2 \) |
"cell in block stride" | Count of cells in a block stride | Size | \( 1 \times 1 \) ~ \( 64 \times 64 \) | \( 1 \times 1 \) |
"block stride step" | Count of stride block | Size | | \( 1 \times 1 \) |
"signed gradient" | Use signed gradient or not, directions are analyzed in 360 or 180 degree | Bool | | false |
|
AKAZE | Accelerated-KAZE
Parameter Name | Usage | Type | Range | Default |
"count" | Count of vocabulary in Bag-of-Words | Integer | 8 ~ 2048 | 64 |
"rotation invariant" | Whether this feature is rotation-invariant | Bool | | true |
"accept threshold" | Threshold to accept key point | Double | > 0 | 10 |
"octave" | Maximum octave evolution | Integer | 1 ~ 5 | 3 |
"sub-level" | Number of sub-levels per scale level(octave) | Integer | > 0 | 4 |
"conductivity" | Conductivity coefficient | Integer | see LPVConductivity | G2 |
|
Example Code
C++
ILFeaturePtr hog = LFeature::Create();
hog->Type = LPVFeatureType::LPVFeatureHOG;
hog->PutParamSize(L"cell size", LSize{ 8, 8 });
hog->PutParamI(L"bin size", 5);
hog->PutParamSize(L"cell in block", LSize{ 4, 4 });
llc->AddFeature(hog);
C#
LFeature hog = new LFeature();
hog.ParamSize["cell size"] = new LSize{ w = 8, h = 8 };
hog.ParamI["bin size"] = 5;
hog.ParamSize["cell in block"] = new LSize { w = 4, h = 4 };
llc.AddFeature(hog);
LPVFeatureType
This enumeration represents the type of feature extracted from the image.
Definition: LPVML.idl:89
COM
ILFeaturePtr hog = LFeature::Create();
hog->Type = LPVFeatureType::LPVFeatureHOG;
hog->ParamSize[L"cell size"] = LSize{ 8, 8 };
hog->ParamI[L"bin size"] = 5;
hog->ParamSize[L"cell in block"] = LSize{ 4, 4 };
llc->AddFeature(hog);