#include <SingleSampler.h>
|
| SingleSampler (int numPos, int numNeg) |
|
int | GetNumPos () const |
|
int | GetNumNeg () const |
|
const Rect & | GetPosSample (int index) const |
|
const Rect & | GetNegSample (int index) const |
|
virtual void | Sample (const Rect &pos, const Size &imgSize) |
|
void | DrawSamples (cv::Mat &img, const cv::Scalar &posColor, const cv::Scalar &negColor) const |
|
void | DrawSample (cv::Mat &img, const cv::Scalar &color, int index=0, int target=1) const |
|
|
int | numNegSamples |
|
int | numPosSamples |
|
Rect * | negSamples |
|
Rect * | posSamples |
|
int | curPosSample |
|
int | curNegSample |
|
std::normal_distribution< float > | gaussianWidth |
|
std::normal_distribution< float > | gaussianHeight |
|
|
static std::default_random_engine | generator |
|
Sampler interface. This is used to sample neg and pos examples. Given a positive sample, it samples numNegSamples negative samples around it.
- Author
- Zhengrong Wang, Hsienyu Meng.
void SingleSampler::DrawSample |
( |
cv::Mat & |
img, |
|
|
const cv::Scalar & |
color, |
|
|
int |
index = 0 , |
|
|
int |
target = 1 |
|
) |
| const |
Draw a specific sample.
- Parameters
-
img | the image to draw |
color | color we will use |
index | the index of the sample |
target | positive or negative samples |
The documentation for this class was generated from the following files: