18 #include <boost/function.hpp> 34 : theFrontDets(innerDets.
begin(), innerDets.
end()), theBackDets(outerDets.
begin(), outerDets.
end()) {
47 LogDebug(
"TkDetLayers") <<
"DEBUG INFO for CompositeTECWedge" 49 <<
"TECWedge z, perp,innerRadius,outerR: " << this->
position().
z() <<
" , " 54 LogDebug(
"TkDetLayers") <<
"frontDet phi,z,r: " << (*it)->surface().position().phi() <<
" , " 55 << (*it)->surface().position().z() <<
" , " << (*it)->surface().position().perp();
59 LogDebug(
"TkDetLayers") <<
"backDet phi,z,r: " << (*it)->surface().phi() <<
" , " << (*it)->surface().position().z()
60 <<
" , " << (*it)->surface().position().perp();
68 throw DetLayerException(
"CompositeTECWedge doesn't have GeometricSearchDet components");
74 edm::LogError(
"TkDetLayers") <<
"temporary dummy implementation of CompositeTECWedge::compatible()!!";
75 return pair<bool, TrajectoryStateOnSurface>();
81 std::vector<DetGroup>&
result)
const {
86 std::vector<DetGroup> closestResult;
89 LogDebug(
"TkDetLayers") <<
"in CompositeTECWedge::groupedCompatibleDets,closestResult.size(): " 90 << closestResult.size();
92 if (closestResult.empty())
100 std::vector<DetGroup> nextResult;
120 if (!frontPath.first)
130 LogDebug(
"TkDetLayers") <<
"in TECWedge,front crossing r,z,phi: (" << gFrontPoint.perp() <<
"," << gFrontPoint.z()
131 <<
"," << gFrontPoint.phi() <<
")";
133 LogDebug(
"TkDetLayers") <<
"in TECWedge,back crossing r,z,phi: (" << gBackPoint.perp() <<
"," << gBackPoint.z() <<
"," 134 << gBackPoint.phi() <<
")" << endl;
155 if (frontDist < backDist) {
166 vector<DetGroup>&
result)
const {
169 LogDebug(
"TkDetLayers") <<
"in CompositeTECWedge,adding GeomDet at r,z,phi: (" 183 bool checkClosest)
const {
189 int negStartIndex = closestIndex - 1;
190 int posStartIndex = closestIndex + 1;
194 posStartIndex = closestIndex;
196 negStartIndex = closestIndex;
201 for (
int idet = negStartIndex; idet >= 0; idet--) {
205 if (!
Adder::add(*sWedge[idet], tsos, prop, est, result))
208 for (
int idet = posStartIndex; idet < static_cast<int>(sWedge.size()); idet++) {
212 if (!
Adder::add(*sWedge[idet], tsos, prop, est, result))
221 auto closeDist =
std::abs((myDets.front()->toLocal(startPos)).
x());
222 for (
unsigned int i = 1;
i < myDets.size();
i++) {
224 if (dist < closeDist) {
CompositeTECWedge(std::vector< const GeomDet * > &innerDets, std::vector< const GeomDet * > &outerDets) __attribute__((cold))
std::vector< const GeomDet * > theDets
int closestDetIndex() const
GlobalPoint globalPosition() const
GeometricSearchDet::DetWithState DetWithState
SubLayerCrossings computeCrossings(const TrajectoryStateOnSurface &tsos, PropagationDirection propDir) const __attribute__((hot))
LocalVector toLocal(const reco::Track::Vector &v, const Surface &s)
~CompositeTECWedge() override __attribute__((cold))
bool overlapInPhi(float phi, const GeomDet &det, float phiWindow)
const Plane & surface() const
The nominal surface of the GeomDet.
ReferenceCountingPointer< BoundDiskSector > theDiskSector
std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &ts, const Propagator &, const MeasurementEstimator &) const override __attribute__((cold))
const GlobalPoint & position() const
std::vector< const GeomDet * > theFrontDets
float computeWindowSize(const GeomDet *det, const TrajectoryStateOnSurface &tsos, const MeasurementEstimator &est)
std::pair< bool, double > pathLength(const Plane &plane) override
int findClosestDet(const GlobalPoint &startPos, int sectorId) const
const std::vector< const GeomDet * > & subWedge(int ind) const
virtual PropagationDirection propagationDirection() const final
std::vector< const GeomDet * > theBackDets
int subLayerIndex() const
Abs< T >::type abs(const T &t)
static int endcapSide(const TrajectoryStateOnSurface &startingState, const Propagator &prop)
void groupedCompatibleDetsV(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est, std::vector< DetGroup > &result) const override __attribute__((hot))
def window(xmin, xmax, ymin, ymax, x=0, y=0, width=100, height=100, xlogbase=None, ylogbase=None, minusInfinity=-1000, flipx=False, flipy=True)
ReferenceCountingPointer< BoundDiskSector > theBackSector
bool phiLess(float phi1, float phi2)
const SubLayerCrossing & other() const
static bool add(const GeometricSearchDet &det, const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, std::vector< DetGroup > &result) __attribute__((hot))
void add(std::map< std::string, TH1 * > &h, TH1 *hist)
virtual const Surface::PositionType & position() const
Returns position of the surface.
void searchNeighbors(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, const SubLayerCrossing &crossing, float window, std::vector< DetGroup > &result, bool checkClosest) const __attribute__((hot))
const SubLayerCrossing & closest() const
GlobalVector globalMomentum() const
bool addClosest(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, const SubLayerCrossing &crossing, std::vector< DetGroup > &result) const __attribute__((hot))
static void orderAndMergeTwoLevels(std::vector< DetGroup > &&one, std::vector< DetGroup > &&two, std::vector< DetGroup > &result, int firstIndex, int firstCrossed)
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
const std::vector< const GeometricSearchDet * > & components() const override __attribute__((cold))
Returns basic components, if any.
PositionType position(double s) const override
ReferenceCountingPointer< BoundDiskSector > theFrontSector
double transverseCurvature() const