VAT
3.0
Video Analysis Tool
|
#include <PoppeFootball.h>
Public Member Functions | |
PoppeFootball (Datapool *i_data) | |
PoppeFootball::PoppeFootball PoppeFootball module. This is an implementation for "Multi-Camera Analysis of Soccer Sequences" from Chris Poppe et. al paper, used to tracking football players with a single-view camera. More... | |
~PoppeFootball () | |
PoppeFootball::~PoppeFootball Destructor. | |
bool | setParameters (QDomNode &config) |
PoppeFootball::setParameters Inherited from ModuleInterface class virtual method. SetParameters reads the XML configuration file (default_config.xml?) and allows to pass those parameters to our variables. Please refer to this class reference to see what XML configuration is needed. More... | |
bool | init () |
PoppeFootball::init This is first called when the module is initialized. More... | |
bool | run () |
PoppeFootball::run This is run for each frame. The main processing is made here. More... | |
bool | updateParameters () |
PoppeFootball::updateParameters I have absolutely no idea what does this function do. More... | |
void | retrieveFGMask () |
PoppeFootball::retrieveFGMask Run operation to get the segmentation image. It is based in a codebook model whose parameters you can adjust using the XML config file (see the class description for more details). It's important to set those parameters properly in order to get a good FG mask. If relatively too much foreground is detected, the Codebook model is considered stale and learned again. This function also takes care of resetting the variables in order to resume that cycle in the run function. The output of this function is the segmentation: the Datapool (m_data->fgImage) foreground mask is updated for a Connected Components algorithm to be applied to it. | |
void | prepareStructuralElem (cv::Mat &output, morpho_param par) |
PoppeFootball::prepareStructuralElem Prepares a Mat with a structural element for morphology operations. More... | |
cv::Scalar | colorName (QString colorcode, bool *convsuccess=NULL) |
PoppeFootball::colorName Transforms a "#RRGGBB" string into a scalar. Support for color names intended, but not implemented. More... | |
cv::Scalar | colorToHSV (cv::Scalar BGRinput) |
![]() | |
ModuleInterface (Datapool *i_data) | |
void | addParameter (QString name, QString value, QString type) |
void | addParameterChild (QString name, QString value, QString type, parameter *parent) |
parameter * | getParameter (QString name) |
parameter * | getParameter (QString name, parameter *parent) |
parameter * | getParameter (QString name, std::multimap< QString, parameter > subList) |
Parameter2 * | getParameterFromTree (const QString name) |
Parameter2 * | getParameterFromTree (const QString name, Parameter2 *parent) |
Parameter2 * | getParameterFromTree (const QString name, std::multimap< QString, Parameter2 > subList) |
void | addParameterToTree (const QString name, const QString value, const QString defaultValue, const ParameterDataType &type) |
void | addChildParameterToTree (const QString &name, const QString &value, const QString &defaultValue, const ParameterDataType &type, Parameter2 *parent) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const bool &defaulValue, bool &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const char &defaulValue, char &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const uchar &defaulValue, uchar &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const int &defaulValue, int &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const uint &defaulValue, uint &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const long &defaulValue, long &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const ulong &defaulValue, ulong &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const float &defaulValue, float &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const double &defaulValue, double &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | getParameterValueFromXml (const QDomNode &rootNode, const QString ¶meterName, const QString &defaulValue, QString &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const bool defaulValue, bool &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const int defaulValue, int &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const char defaulValue, char &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const uchar defaulValue, uchar &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const uint defaulValue, uint &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const long defaulValue, long &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const ulong defaulValue, ulong &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const float defaulValue, float &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const double defaulValue, double &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setNodeParameterModule (const QDomNode &rootNode, const QString ¶meterName, const QString defaulValue, QString &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const bool defaulValue, bool &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const int defaulValue, int &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const char defaulValue, char &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const uchar defaulValue, uchar &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const uint defaulValue, uint &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const long defaulValue, long &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const ulong defaulValue, ulong &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const float defaulValue, float &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const double defaulValue, double &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
bool | setChildParameterModule (const QDomNode &rootNode, const QString ¶meterName, const QString defaulValue, QString &outParameter, QDomNode ¶meterNode, bool appendWarning=false) |
Additional Inherited Members | |
![]() | |
std::deque< QString > | nameParameters |
std::deque< QString > | valueParameters |
std::deque< QString > | typeParameters |
std::deque< parameter > | listParameters |
std::deque< Parameter2 > | parametersTree |
std::string | name |
ModuleType | type |
![]() | |
Datapool * | m_data |
It's a VAT Module, so it inherits from ModuleInterface for it to be integrated with the workbench.
How to integrate this module into VAT: It's a rather simple task. All we have to do is:
This module relies on a lot of external functions, declared in CommonImage and CodebookModel classes. As interaction between Qt and OpenCV's image formats sure gave us more than one headache, we hope these will be useful for another projects besides ours.
TODO:
TO VIEW OUR RESULTS:
XML CONFIG PARAMETERS:
RECOMMENDED USE OF THIS MODULE: This is a segmentation module, it should be used after an adquisition module (like a camera or a video file). Blobs must be taken from the results of this module. Then, the order should be the following:
PoppeFootball::PoppeFootball | ( | Datapool * | i_data | ) |
PoppeFootball::PoppeFootball PoppeFootball module. This is an implementation for "Multi-Camera Analysis of Soccer Sequences" from Chris Poppe et. al paper, used to tracking football players with a single-view camera.
i_data | Module parameter for VAT, centralizes every captured frame. |
Scalar PoppeFootball::colorName | ( | QString | colorcode, |
bool * | convsuccess = NULL |
||
) |
PoppeFootball::colorName Transforms a "#RRGGBB" string into a scalar. Support for color names intended, but not implemented.
colorcode |
|
virtual |
PoppeFootball::init This is first called when the module is initialized.
Implements ModuleInterface.
void PoppeFootball::prepareStructuralElem | ( | cv::Mat & | output, |
morpho_param | par | ||
) |
PoppeFootball::prepareStructuralElem Prepares a Mat with a structural element for morphology operations.
output | Output Mat |
par | Structural element parameters |
|
virtual |
PoppeFootball::run This is run for each frame. The main processing is made here.
Implements ModuleInterface.
|
virtual |
PoppeFootball::setParameters Inherited from ModuleInterface class virtual method. SetParameters reads the XML configuration file (default_config.xml?) and allows to pass those parameters to our variables. Please refer to this class reference to see what XML configuration is needed.
config | Holds the config XML nodes. |
Implements ModuleInterface.
|
virtual |
PoppeFootball::updateParameters I have absolutely no idea what does this function do.
Implements ModuleInterface.