Main Page
Namespaces
Classes
Package Documentation
RecoTracker
TkTrackingRegions
src
OuterHitCompatibility.h
Go to the documentation of this file.
1
#ifndef RecoTracker_TkTrackingRegions_OuterHitCompatibility_H
2
#define RecoTracker_TkTrackingRegions_OuterHitCompatibility_H
3
4
10
#include "
FWCore/Framework/interface/EventSetup.h
"
11
#include "
DataFormats/GeometryVector/interface/GlobalPoint.h
"
12
#include "
OuterHitPhiPrediction.h
"
13
#include "
RecoTracker/TkTrackingRegions/interface/HitRZCompatibility.h
"
14
#include "
DataFormats/TrackingRecHit/interface/TrackingRecHit.h
"
15
#include "
TrackingTools/TransientTrackingRecHit/interface/TransientTrackingRecHit.h
"
16
17
#include "
TrackingTools/DetLayers/interface/PhiLess.h
"
18
#include "
DataFormats/Math/interface/approx_atan2.h
"
19
20
#include "
FWCore/Utilities/interface/Visibility.h
"
21
22
template
<
typename
Algo>
23
class
dso_internal
OuterHitCompatibility
{
24
public
:
25
26
OuterHitCompatibility
(
27
const
OuterHitPhiPrediction
& phiPrediction,
28
const
Algo
& rzCompatibility)
29
: thePhiPrediction(phiPrediction),
30
theRZCompatibility(rzCompatibility) {}
31
32
bool
operator() (
const
TrackingRecHit
&
hit
)
const
{
33
34
auto
hitPos = hit.
globalPosition
();
35
auto
hitR = hitPos.
perp
();
36
37
auto
hitZ = hitPos.z();
38
if
( !theRZCompatibility(hitR,hitZ) )
return
false
;
39
40
auto
hitPhi = unsafe_atan2f<9>(hitPos.y(),hitPos.x());
41
42
return
checkPhi(hitPhi, hitR);
43
}
44
45
46
bool
checkPhi
(
float
phi
,
float
r
)
const
{
47
auto
hitPhiRange = thePhiPrediction(r);
48
PhiLess
less;
49
bool
phiOK = less(hitPhiRange.min(),
phi
) && less(phi,hitPhiRange.max());
50
return
phiOK;
51
}
52
53
private
:
54
OuterHitPhiPrediction
thePhiPrediction
;
55
Algo
theRZCompatibility
;
56
};
57
#endif
approx_atan2.h
PV3DBase::perp
T perp() const
Definition:
PV3DBase.h:72
OuterHitPhiPrediction.h
EventSetup.h
TrackingRecHit
Definition:
TrackingRecHit.h:23
OuterHitPhiPrediction
Definition:
OuterHitPhiPrediction.h:12
TrackingRecHit::globalPosition
virtual GlobalPoint globalPosition() const
Definition:
TrackingRecHit.cc:47
DDAxes::phi
PhiLess
Definition:
PhiLess.h:12
TransientTrackingRecHit.h
Visibility.h
TrackingRecHit.h
OuterHitCompatibility::theRZCompatibility
Algo theRZCompatibility
Definition:
OuterHitCompatibility.h:55
HitRZCompatibility.h
alignCSCRings.r
r
Definition:
alignCSCRings.py:92
PhiLess.h
hit
Definition:
SiStripHitEffFromCalibTree.cc:85
dso_internal
#define dso_internal
OuterHitCompatibility::checkPhi
bool checkPhi(float phi, float r) const
Definition:
OuterHitCompatibility.h:46
OuterHitCompatibility
Definition:
OuterHitCompatibility.h:23
OuterHitCompatibility::thePhiPrediction
OuterHitPhiPrediction thePhiPrediction
Definition:
OuterHitCompatibility.h:54
Algo
Definition:
fakeMenu.h:6
OuterHitCompatibility::OuterHitCompatibility
OuterHitCompatibility(const OuterHitPhiPrediction &phiPrediction, const Algo &rzCompatibility)
Definition:
OuterHitCompatibility.h:26
GlobalPoint.h
Generated for CMSSW Reference Manual by
1.8.11