PedestrainCounting
|
#include <MatchMatrix.h>
Classes | |
struct | MatchScore |
Public Member Functions | |
MatchMatrix (int capacity) | |
void | SetNumDets (int numDets) |
void | SetTargets (std::vector< int > &targets, float threshold) |
void | PrintMatchMatrix () |
Public Attributes | |
const int | capacity |
std::vector< MatchScore > | matchMatrix |
std::vector< char > | isDetMatched |
Use greedy algorithm to find best (detection, target) pair.
void MatchMatrix::PrintMatchMatrix | ( | ) |
Print the match score matrix for debugging.
void MatchMatrix::SetNumDets | ( | int | numDets | ) |
Set the number of detections. Should be called before calculating match score matrix.
void MatchMatrix::SetTargets | ( | std::vector< int > & | targets, |
float | threshold | ||
) |
After calculating the matching score matrix, use greedy algorithm to find the (target, detection) pair. Only match score > threshold are considered.
const int MatchMatrix::capacity |
How many targets?
std::vector<char> MatchMatrix::isDetMatched |
Is this detection has already matched to some targert? Avoid using std::vector<char>.
std::vector<MatchScore> MatchMatrix::matchMatrix |
The match score matrix. It should be (capacity # detections).