@Reference(type=Article, author={"Ojala, T.","Pietikainen, M.","Maenpaa, T."}, title="Multiresolution gray-scale and rotation invariant texture classification with local binary patterns", year="2002", journal="Pattern Analysis and Machine Intelligence, IEEE Transactions on", pages={"971 ","987"}, month="jul", number="7", volume="24", customData={"doi","10.1109/TPAMI.2002.1017623","ISSN","0162-8828"}) public class UniformBinaryPattern extends Object
The class caches lookup tables of uniform patterns on demand, with the exception of the commonly used 8-bit patterns which are cached on initialization.
Modifier and Type | Field and Description |
---|---|
protected static gnu.trove.map.hash.TIntObjectHashMap<gnu.trove.list.array.TIntArrayList> |
lut |
Constructor and Description |
---|
UniformBinaryPattern() |
Modifier and Type | Method and Description |
---|---|
protected static gnu.trove.list.array.TIntArrayList |
calculateUniformPatterns(int nbits) |
static FImage |
extractPatternImage(int[][] patternImage,
int code)
Compute a binary map showing the locations of the specified pattern code.
|
static FImage[] |
extractPatternImages(int[][] patternImage,
int nbits)
Compute all binary maps for each possible pattern code given the number
of bits used to encode patterns.
|
static boolean[][][] |
extractPatternMaps(int[][] patternImage,
int nbits)
Compute all binary maps for each possible pattern code given the number
of bits used to encode patterns.
|
static List<List<Pixel>> |
extractPatternPixels(int[][] patternImage,
int nbits)
Compute all pixels matching each possible pattern code given the number
of bits used to encode patterns.
|
static gnu.trove.list.array.TIntArrayList |
getUniformPatterns(int nbits)
Get a list of all the binary patterns of a given length that are
"uniform".
|
static boolean |
isPatternUniform(int pattern,
int nbits)
Check whether the given nbits pattern is uniform.
|
protected static boolean |
isUniform(boolean[] pattern) |
protected static gnu.trove.map.hash.TIntObjectHashMap<gnu.trove.list.array.TIntArrayList> lut
public UniformBinaryPattern()
protected static gnu.trove.list.array.TIntArrayList calculateUniformPatterns(int nbits)
protected static boolean isUniform(boolean[] pattern)
public static gnu.trove.list.array.TIntArrayList getUniformPatterns(int nbits)
nbits
- pattern lengthpublic static boolean isPatternUniform(int pattern, int nbits)
pattern
- the patternnbits
- the pattern lengthpublic static FImage extractPatternImage(int[][] patternImage, int code)
patternImage
- the pattern datacode
- the code to extractFImage
depicting the locations of the given codepublic static FImage[] extractPatternImages(int[][] patternImage, int nbits)
patternImage
- the pattern datanbits
- the number of bits for the patternspublic static boolean[][][] extractPatternMaps(int[][] patternImage, int nbits)
patternImage
- the pattern datanbits
- the number of bits for the patternspublic static List<List<Pixel>> extractPatternPixels(int[][] patternImage, int nbits)
patternImage
- the pattern datanbits
- the number of bits for the patterns