A template-matching channel for detecting pedestrians. More...
#include <Channels/ObjDetChannel.H>
Public Member Functions | |
ObjDetChannel (OptionManager &mgr, const std::string &descrName=std::string("ObjDetChannel"), const std::string &=std::string("ObjDetChannel")) | |
Constructor. | |
virtual bool | outputAvailable () const |
overload | |
virtual | ~ObjDetChannel () |
Virtual destructor. | |
virtual uint | numSubmaps () const |
Return the number of feature maps represented by this channel. | |
virtual Image< float > | getSubmap (const uint index) const |
Get the feature map at the given index. | |
virtual std::string | getSubmapName (const uint index) const |
Get the name/description of the feature map at the given index. | |
virtual std::string | getSubmapNameShort (const uint index) const |
Get the name/description of the feature map at the given index, short version. | |
virtual void | doInput (const InputFrame &inframe) |
special input function | |
virtual Image< float > | getOutput () |
special output function | |
virtual Dims | getMapDims () const |
Return the dimensions of the output image. | |
virtual void | getFeatures (const Point2D< int > &locn, std::vector< float > &mean) const |
virtual void | getFeaturesBatch (std::vector< Point2D< int > * > *locn, std::vector< std::vector< float > > *mean, int *count) const |
Protected Attributes | |
Image< float > | itsMap |
our face map | |
OModelParam< LevelSpec > | itsLevelSpec |
OModelParam< std::string > | itsCascadeFile |
OModelParam< MaxNormType > | itsNormType |
OModelParam< float > | itsOutputRangeMin |
Set a fixed range of values for the raw output. | |
OModelParam< float > | itsOutputRangeMax |
OModelParam< bool > | itsUseRandom |
NModelParam< bool > | itsNormalizeOutput |
CvMemStorage * | storage |
CvHaarClassifierCascade * | cascade |
A template-matching channel for detecting pedestrians.
Definition at line 49 of file ObjDetChannel.H.
ObjDetChannel::ObjDetChannel | ( | OptionManager & | mgr, | |
const std::string & | descrName = std::string("ObjDetChannel") , |
|||
const std::string & | tagName = std::string("ObjDetChannel") | |||
) |
ObjDetChannel::~ObjDetChannel | ( | ) | [virtual] |
Virtual destructor.
Definition at line 83 of file ObjDetChannel.C.
void ObjDetChannel::doInput | ( | const InputFrame & | inframe | ) | [virtual] |
special input function
Implements ChannelBase.
Definition at line 151 of file ObjDetChannel.C.
References ASSERT, getMapDims(), OModelParam< T >::getVal(), NModelParam< T >::getVal(), Rectangle::height(), Point2D< T >::i, img2ipl(), Image< T >::initialized(), inplaceAddBGnoise(), inplaceNormalize(), inplaceRectify(), itsMap, itsOutputRangeMin, lum, maxNormalize(), maxNormTypeName(), rescale(), ModelComponent::tagName(), Rectangle::topLeft(), Rectangle::width(), and ZEROS.
Dims ObjDetChannel::getMapDims | ( | ) | const [virtual] |
Return the dimensions of the output image.
Implements ChannelBase.
Definition at line 97 of file ObjDetChannel.C.
References ChannelBase::getInputDims(), OModelParam< T >::getVal(), Dims::h(), ChannelBase::hasInput(), LevelSpec::mapLevel(), and Dims::w().
Referenced by doInput().
Image< float > ObjDetChannel::getOutput | ( | ) | [virtual] |
special output function
Implements ChannelBase.
Definition at line 238 of file ObjDetChannel.C.
References itsMap.
Get the feature map at the given index.
This function is intended to be implemented by subclasses so that it recurses into any nested channels, mapping nested submaps into a linear sequence of indices.
Implements ChannelBase.
Definition at line 216 of file ObjDetChannel.C.
References itsMap.
std::string ObjDetChannel::getSubmapName | ( | const uint | index | ) | const [virtual] |
Get the name/description of the feature map at the given index.
This function is intended to be implemented by subclasses so that it recurses into any nested channels, mapping nested submaps into a linear sequence of indices. The output of this function is intended only to be human-readable (e.g. for labeling image displays), and does not have to follow any particular parseable syntax.
Implements ChannelBase.
Definition at line 225 of file ObjDetChannel.C.
std::string ObjDetChannel::getSubmapNameShort | ( | const uint | index | ) | const [virtual] |
Get the name/description of the feature map at the given index, short version.
Implements ChannelBase.
Definition at line 231 of file ObjDetChannel.C.
uint ObjDetChannel::numSubmaps | ( | ) | const [virtual] |
Return the number of feature maps represented by this channel.
Implements ChannelBase.
Definition at line 91 of file ObjDetChannel.C.
bool ObjDetChannel::outputAvailable | ( | ) | const [virtual] |
overload
Implements ChannelBase.
Definition at line 87 of file ObjDetChannel.C.
References Image< T >::initialized(), and itsMap.
Image<float> ObjDetChannel::itsMap [protected] |
our face map
Definition at line 85 of file ObjDetChannel.H.
Referenced by doInput(), getOutput(), getSubmap(), and outputAvailable().
OModelParam<float> ObjDetChannel::itsOutputRangeMin [protected] |
Set a fixed range of values for the raw output.
Definition at line 91 of file ObjDetChannel.H.
Referenced by doInput().