Definition at line 142 of file DBScanAlg.cxx.
AcceptFindNeighbors::AcceptFindNeighbors |
( |
const BoundingBox & |
b, |
|
|
double |
eps, |
|
|
double |
eps2, |
|
|
double |
maxWidth, |
|
|
double |
wireDist, |
|
|
std::vector< unsigned int > & |
badWireSum |
|
) |
| |
|
inline |
Definition at line 148 of file DBScanAlg.cxx.
const BoundingBox & fBound
std::vector< unsigned int > & fBadWireSum
bool AcceptFindNeighbors::isNear |
( |
const BoundingBox & |
b | ) |
const |
|
inline |
- Todo:
- activating these should throw a warning or something
Definition at line 168 of file DBScanAlg.cxx.
References util::absDiff(), e, and RStarBoundingBox< dimensions >::edges.
176 double bWidth = std::abs( b.
edges[1].second - b.
edges[1].first);
179 unsigned int wire1 = (
unsigned int) (tCenter0/
fWireDist + 0.5);
180 unsigned int wire2 = (
unsigned int) (bCenter0/
fWireDist + 0.5);
189 double cmtobridge = wirestobridge*
fWireDist;
192 double sim = std::abs(tCenter0 - bCenter0) - cmtobridge;
196 if ( std::abs(tCenter0 - bCenter0) > 1
e-10 ) {
197 cmtobridge *= std::abs((tCenter1-bCenter1)/(tCenter0-bCenter0));
199 double sim2 = std::abs(tCenter1 - bCenter1) - cmtobridge;
208 double WFactor = (exp(4.6*((tWidth*tWidth)+(bWidth*bWidth))))*k;
210 if (WFactor<1.0) WFactor = 1.0;
211 if (WFactor>6.25) WFactor = 6.25;
214 return (((sim )/(
fEps[0]*
fEps[0]) ) +
215 ((sim2)/(fEps[1]*fEps[1]*(WFactor))) <= 1 );
const BoundingBox & fBound
std::vector< unsigned int > & fBadWireSum
constexpr auto absDiff(A const &a, B const &b)
Returns the absolute value of the difference between two values.
std::pair< double, double > edges[dimensions]
BoundingBox center() const
bool AcceptFindNeighbors::operator() |
( |
const RTree::Node *const |
node | ) |
const |
|
inline |
bool AcceptFindNeighbors::operator() |
( |
const RTree::Leaf *const |
leaf | ) |
const |
|
inline |
Definition at line 247 of file DBScanAlg.cxx.
248 return isNear(leaf->bound);
bool isNear(const BoundingBox &b) const
std::vector< unsigned int >& AcceptFindNeighbors::fBadWireSum |
double AcceptFindNeighbors::fEps[2] |
double AcceptFindNeighbors::fMaxWidth |
double AcceptFindNeighbors::fWireDist |
The documentation for this struct was generated from the following file: