Getting StartedΒΆ
Load the module and instantiate the descriptor:
from hogpp import IntegralHOGDescriptor desc = IntegralHOGDescriptor()
Load the image and precompute its integral histogram R-HOG representation. This needs to be done only once per image:
desc.compute(image)
Extract the feature descriptor of a region of interest using a function call on a
hogpp.IntegralHOGDescriptorinstance, i.e., by invokinghogpp.IntegralHOGDescriptor.__call__(). The method can be called multiple times for different subregions of the image whose integral histogram representation was previously precomputed.# top left (row, column) size (height, width) roi = (0, 0, 128, 64) X = desc(roi)
Note
hogpp.IntegralHOGDescriptor uses matrix indexing along each axis
as opposed to Cartesian coordinates, i.e., the first index corresponds to
the vertical (\(y\)) coordinate, the second index to the horizontal
(\(x\)) coordinate, etc.