![Logo](../../ATLAS-Logo-Square-Blue-RGB.png) |
ATLAS Offline Software
|
Go to the documentation of this file.
12 #include "../TrackParametersHelper.h"
24 PlotMgr* pParent,
const std::string& dirName,
25 const std::string& anaTag,
const std::string& trackType ) :
26 PlotMgr( dirName, anaTag, pParent ),
27 m_trackType( trackType ) { }
36 if(
sc.isFailure() ) {
44 ATH_MSG_DEBUG(
"Booking resolution plots in " << getDirectory() );
46 for(
unsigned int i=0;
i<NPARAMS;
i++){
48 "resHelper_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
49 ATH_CHECK( retrieveAndBook( m_reswidth_vs_eta[
i],
50 "resolution_vs_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
51 ATH_CHECK( retrieveAndBook( m_resmean_vs_eta[
i],
52 "resmean_vs_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
54 ATH_CHECK( retrieveAndBook( m_pullHelperEta[
i],
55 "pullHelper_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
56 ATH_CHECK( retrieveAndBook( m_pullwidth_vs_eta[
i],
57 "pullwidth_vs_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
58 ATH_CHECK( retrieveAndBook( m_pullmean_vs_eta[
i],
59 "pullmean_vs_"+m_trackType+
"_eta_" + m_paramProp[
i] ) );
62 "resHelper_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
63 ATH_CHECK( retrieveAndBook( m_reswidth_vs_pt[
i],
64 "resolution_vs_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
65 ATH_CHECK( retrieveAndBook( m_resmean_vs_pt[
i],
66 "resmean_vs_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
68 "corr_"+m_trackType+
"_"+m_paramProp[
i]));
70 "pullHelper_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
71 ATH_CHECK( retrieveAndBook( m_pullwidth_vs_pt[
i],
72 "pullwidth_vs_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
73 ATH_CHECK( retrieveAndBook( m_pullmean_vs_pt[
i],
74 "pullmean_vs_"+m_trackType+
"_pt_" + m_paramProp[
i] ) );
77 return StatusCode::SUCCESS;
84 template<
typename REF,
typename TEST >
86 const REF& particle_ref,
const TEST& track_test,
float weight )
90 float testErrorP[NPARAMS];
92 refP[D0] =
d0(particle_ref);
93 refP[
Z0] =
z0(particle_ref);
96 refP[THETA] =
theta(particle_ref);
97 refP[
PHI] =
phi(particle_ref);
101 testP[D0] =
d0(track_test);
102 testP[
Z0] =
z0(track_test);
105 testP[THETA] =
theta(track_test);
106 testP[
PHI] =
phi(track_test);
119 float eta_ref =
eta(particle_ref);
122 for(
unsigned int i=0;
i<NPARAMS;
i++){
137 return StatusCode::SUCCESS;
164 for (
unsigned int i = 0;
i < NPARAMS;
i++) {
166 m_reswidth_vs_eta[
i], m_resmean_vs_eta[
i],
170 m_reswidth_vs_pt[
i], m_resmean_vs_pt[
i],
TEST(CombinationsGeneratorTester, n3k1)
float trackParameterError(const U &p, Trk::ParamDefs param)
float qOverPtError(const U &p)
void makeResolutions(const TH2 *h_input2D, TH1 *hwidth, TH1 *hmean, TH1 *hproj[], bool saveProjections, IDPVM::ResolutionHelper::methods theMethod=IDPVM::ResolutionHelper::iterRMS_convergence)
extract 1D resolution plots from a 2D "residual vs observable" histogram.
template StatusCode IDTPM::ResolutionPlots::fillPlots< xAOD::TrackParticle, xAOD::TruthParticle >(const xAOD::TrackParticle &, const xAOD::TruthParticle &, float weight)
double deltaPhi(double phiA, double phiB)
delta Phi in range [-pi,pi[
void initializePlots()
Book the histograms.
template StatusCode IDTPM::ResolutionPlots::fillPlots< xAOD::TrackParticle, xAOD::TrackParticle >(const xAOD::TrackParticle &, const xAOD::TrackParticle &, float weight)
float phi(const U &p)
Accessor utility function for getting the value of phi.
template StatusCode IDTPM::ResolutionPlots::fillPlots< xAOD::TruthParticle, xAOD::TrackParticle >(const xAOD::TruthParticle &, const xAOD::TrackParticle &, float weight)
float pTError(const U &p)
float z0SinTheta(const U &p)
float qOverPT(const U &p)
float eta(const U &p)
Accessor utility function for getting the value of eta.
::StatusCode StatusCode
StatusCode definition for legacy code.
Class describing a truth particle in the MC record.
float pT(const U &p)
Accessor utility function for getting the value of pT.
void finalizePlots()
Print out final stats on histograms.
float z0SinThetaError(const U &p)
ResolutionPlots(PlotMgr *pParent, const std::string &dirName, const std::string &anaTag, const std::string &trackType)
Constructor.
template StatusCode IDTPM::ResolutionPlots::fillPlots< xAOD::TruthParticle, xAOD::TruthParticle >(const xAOD::TruthParticle &, const xAOD::TruthParticle &, float weight)
N.B.: not a use-case. Just to avoid compilation errors.
Class describing a TrackParticle.
StatusCode fillPlots(const REF &particle_ref, const TEST &track_test, float weight)
Dedicated fill method (for tracks and/or truth particles)