|
void | Init (unsigned int dx, unsigned int dy, float rhores, unsigned int numACells) |
|
std::array< int, 3 > | AddPointReturnMax (int x, int y) |
|
bool | SubtractPoint (int x, int y) |
|
int | GetCell (int row, int col) const |
|
void | SetCell (int row, int col, int value) |
|
void | GetAccumSize (int &numRows, int &numCols) |
|
int | NumAccumulated () |
|
void | GetEquation (float row, float col, float &rho, float &theta) const |
|
int | GetMax (int &xmax, int &ymax) const |
|
void | reconfigure (fhicl::ParameterSet const &pset) |
|
Definition at line 74 of file HoughBaseAlg.cxx.
Type of the Hough transform (angle, distance) map with custom allocator.
Definition at line 107 of file HoughBaseAlg.cxx.
std::array< int, 3 > cluster::HoughTransform::AddPointReturnMax |
( |
int |
x, |
|
|
int |
y |
|
) |
| |
|
inline |
Definition at line 660 of file HoughBaseAlg.cxx.
662 if ((
x > (
int)
m_dx) || (
y > (
int)
m_dy) ||
x < 0.0 ||
y < 0.0) {
663 std::array<int, 3>
max;
static int max(int a, int b)
std::array< int, 3 > cluster::HoughTransform::DoAddPointReturnMax |
( |
int |
x, |
|
|
int |
y, |
|
|
bool |
bSubtract = false |
|
) |
| |
|
private |
Definition at line 758 of file HoughBaseAlg.cxx.
760 std::array<int, 3>
max;
776 for (
size_t iAngleStep = 1; iAngleStep <
m_numAngleCells; ++iAngleStep) {
806 if (lastDist == dist) {
813 first_dist = dist > lastDist ? lastDist : dist + 1;
814 end_dist = dist > lastDist ? dist : lastDist + 1;
818 if (bSubtract) { distMap.decrement(first_dist, end_dist); }
820 DistancesMap_t::PairValue_t max_counter =
821 distMap.increment_and_get_max(first_dist, end_dist, max_val);
823 if (max_counter.second > max_val) {
828 max = {{max_counter.second, max_counter.first.key(), (
int)iAngleStep}};
829 max_val = max_counter.second;
static int max(int a, int b)
constexpr double dist(const TReal *x, const TReal *y, const unsigned int dimension)
void cluster::HoughTransform::GetAccumSize |
( |
int & |
numRows, |
|
|
int & |
numCols |
|
) |
| |
|
inline |
int cluster::HoughTransform::GetCell |
( |
int |
row, |
|
|
int |
col |
|
) |
| const |
|
inline |
void cluster::HoughTransform::GetEquation |
( |
float |
row, |
|
|
float |
col, |
|
|
float & |
rho, |
|
|
float & |
theta |
|
) |
| const |
int cluster::HoughTransform::GetMax |
( |
int & |
xmax, |
|
|
int & |
ymax |
|
) |
| const |
Definition at line 738 of file HoughBaseAlg.cxx.
741 for (
unsigned int i = 0; i <
m_accum.size(); i++) {
743 DistancesMap_t::PairValue_t max_counter =
m_accum[i].get_max(maxVal);
744 if (max_counter.second > maxVal) {
745 maxVal = max_counter.second;
747 ymax = max_counter.first.key();
void cluster::HoughTransform::Init |
( |
unsigned int |
dx, |
|
|
unsigned int |
dy, |
|
|
float |
rhores, |
|
|
unsigned int |
numACells |
|
) |
| |
Definition at line 681 of file HoughBaseAlg.cxx.
704 <std::pair<const DistancesMap_t::Key_t, DistancesMap_t::CounterBlock_t>>
706 10 * ((1048576 / (40 +
sizeof(DistancesMap_t::CounterBlock_t))) & ~0x1FFU)
721 for (
size_t iAngleStep = 0; iAngleStep <
m_numAngleCells; ++iAngleStep) {
722 double a = iAngleStep * angleStep;
Aggressive allocator reserving a lot of memory in advance.
int cluster::HoughTransform::NumAccumulated |
( |
| ) |
|
|
inline |
void cluster::HoughTransform::SetCell |
( |
int |
row, |
|
|
int |
col, |
|
|
int |
value |
|
) |
| |
|
inline |
bool cluster::HoughTransform::SubtractPoint |
( |
int |
x, |
|
|
int |
y |
|
) |
| |
|
inline |
column (map key)=rho, row (vector index)=theta
Definition at line 117 of file HoughBaseAlg.cxx.
std::vector<double> cluster::HoughTransform::m_cosTable |
|
private |
unsigned int cluster::HoughTransform::m_dx |
|
private |
unsigned int cluster::HoughTransform::m_dy |
|
private |
int cluster::HoughTransform::m_numAccumulated |
|
private |
unsigned int cluster::HoughTransform::m_numAngleCells |
|
private |
float cluster::HoughTransform::m_rhoResolutionFactor |
|
private |
unsigned int cluster::HoughTransform::m_rowLength |
|
private |
std::vector<double> cluster::HoughTransform::m_sinTable |
|
private |
The documentation for this class was generated from the following file: