ATLAS Offline Software
MuonPhiHitSelector.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MuonSegmentCleaner_MuonPhiHitSelector_H
6 #define MuonSegmentCleaner_MuonPhiHitSelector_H
7 
9 #include "GaudiKernel/ServiceHandle.h"
10 #include "GaudiKernel/ToolHandle.h"
15 
16 namespace Trk {
17 class PrepRawData;
18 class RIO_OnTrack;
19 } // namespace Trk
20 
21 class MuonPhiHitSelector : public AthAlgTool, virtual public Muon::IMuonHitSelector {
22  public:
23  MuonPhiHitSelector(const std::string&, const std::string&, const IInterface*);
24  virtual ~MuonPhiHitSelector() = default;
25 
26  StatusCode initialize() override;
27 
32  std::vector<std::unique_ptr<const Trk::MeasurementBase>> select_rio(
33  const double pmom, const std::vector<const Trk::RIO_OnTrack*>& associatedHits,
34  const std::vector<const Trk::PrepRawData*>& unassociatedHits) const override;
35 
36  private:
38  this,
39  "MuonIdHelperSvc",
40  "Muon::MuonIdHelperSvc/MuonIdHelperSvc",
41  };
42 
44  ToolHandle<Muon::IMuonCompetingClustersOnTrackCreator> m_competingRIOsOnTrackTool{
45  this,
46  "MuonCompetingClustersOnTrackCreator",
47  "Muon::MuonCompetingClustersOnTrackCreator/MuonCompetingClustersOnTrackCreator",
48  };
50  ToolHandle<Muon::IMuonClusterOnTrackCreator> m_clusterCreator{this, "MuonClusterOnTrackCreator",""};
51 
52  ToolHandle<Muon::IMuonClusterOnTrackCreator> m_cscRotCreator{this, "CscRotCreator",""};
53 
55  Gaudi::Property<bool> m_summary{this, "DoSummary", false};
57  Gaudi::Property<bool> m_cosmics{this, "DoCosmics", false};
59  Gaudi::Property<bool> m_makeClusters{this, "MakeClusters", false};
61  Gaudi::Property<bool> m_competingRios{this, "CompetingRios", false};
62 
64  void fitRecPhi(const double pmom, const std::vector<Identifier>& phiId, const std::vector<double>& phiHitx,
65  const std::vector<double>& phiHity, const std::vector<double>& phiHitz,
66  const std::vector<double>& phiError, std::vector<int>& quality, const int nphi,
67  std::vector<double>& phiPull, std::vector<int>& phiMult, std::vector<int>& phiSelect, double& chi2,
68  double& r0, double& phi, std::vector<double>& errorM, int& nfit) const;
69 
71  void fitPhiSL(const double pmom, const std::vector<Identifier>& id, const std::vector<double>& hitx,
72  const std::vector<double>& hity, const std::vector<double>& hitz, const std::vector<double>& error,
73  std::vector<int>& select, const int n, std::vector<double>& pull, int& imax, double& chi2, double& r0,
74  double& phi, std::vector<double>& errorM, bool fast) const;
75 
101  void clusterPhi(const std::vector<Identifier>& id, const std::vector<double>& hitx, const std::vector<double>& hity,
102  const std::vector<double>& hitz, const std::vector<double>& error, const std::vector<double>& pull,
103  std::vector<int>& select, const int n, std::vector<double>& clusterX, std::vector<double>& clusterY,
104  std::vector<double>& clusterZ, std::vector<double>& clusterError,
105  std::vector<Identifier>& clusterId, std::vector<int>& clusterHits, std::vector<int>& clusterSelect,
106  std::vector<int>& clusterInt, int& ncl) const;
107 };
108 
109 #endif // MuonSegmentCleaner_MuonPhiHitSelector_H
MuonPhiHitSelector::m_competingRios
Gaudi::Property< bool > m_competingRios
flag that build competing rios on track for amibguous trigger hits (default: false)
Definition: MuonPhiHitSelector.h:61
MuonPhiHitSelector
Definition: MuonPhiHitSelector.h:21
MuonPhiHitSelector::fitRecPhi
void fitRecPhi(const double pmom, const std::vector< Identifier > &phiId, const std::vector< double > &phiHitx, const std::vector< double > &phiHity, const std::vector< double > &phiHitz, const std::vector< double > &phiError, std::vector< int > &quality, const int nphi, std::vector< double > &phiPull, std::vector< int > &phiMult, std::vector< int > &phiSelect, double &chi2, double &r0, double &phi, std::vector< double > &errorM, int &nfit) const
fit method curved track model
Definition: MuonPhiHitSelector.cxx:435
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
MuonPhiHitSelector::fitPhiSL
void fitPhiSL(const double pmom, const std::vector< Identifier > &id, const std::vector< double > &hitx, const std::vector< double > &hity, const std::vector< double > &hitz, const std::vector< double > &error, std::vector< int > &select, const int n, std::vector< double > &pull, int &imax, double &chi2, double &r0, double &phi, std::vector< double > &errorM, bool fast) const
fit method straight line model
Definition: MuonPhiHitSelector.cxx:812
IMuonCompetingClustersOnTrackCreator.h
Muon::IMuonHitSelector
Definition: IMuonHitSelector.h:23
MuonPhiHitSelector::m_cosmics
Gaudi::Property< bool > m_cosmics
flag for use of cosmics, straight line model will be used, no interaction point constraint
Definition: MuonPhiHitSelector.h:57
MuonPhiHitSelector::m_cscRotCreator
ToolHandle< Muon::IMuonClusterOnTrackCreator > m_cscRotCreator
Definition: MuonPhiHitSelector.h:52
MuonPhiHitSelector::initialize
StatusCode initialize() override
Definition: MuonPhiHitSelector.cxx:38
beamspotman.n
n
Definition: beamspotman.py:731
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
IMuonClusterOnTrackCreator.h
AthAlgTool.h
chi2
double chi2(TH1 *h0, TH1 *h1)
Definition: comparitor.cxx:522
TRT_PAI_physicsConstants::r0
const double r0
electron radius{cm}
Definition: TRT_PAI_physicsConstants.h:20
python.StandardJetMods.pull
pull
Definition: StandardJetMods.py:282
MuonPhiHitSelector::m_clusterCreator
ToolHandle< Muon::IMuonClusterOnTrackCreator > m_clusterCreator
Toolhandle to ClusterOnTrackTool creator.
Definition: MuonPhiHitSelector.h:50
imax
int imax(int i, int j)
Definition: TileLaserTimingTool.cxx:33
MuonPhiHitSelector::m_competingRIOsOnTrackTool
ToolHandle< Muon::IMuonCompetingClustersOnTrackCreator > m_competingRIOsOnTrackTool
Toolhandle to CompetingRIOsOnTrackTool creator.
Definition: MuonPhiHitSelector.h:44
MuonPhiHitSelector::~MuonPhiHitSelector
virtual ~MuonPhiHitSelector()=default
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
MuonPhiHitSelector::select_rio
std::vector< std::unique_ptr< const Trk::MeasurementBase > > select_rio(const double pmom, const std::vector< const Trk::RIO_OnTrack * > &associatedHits, const std::vector< const Trk::PrepRawData * > &unassociatedHits) const override
Selects and builds a cleaned vector of RIO fits the associatedHits and build new RIOs,...
Definition: MuonPhiHitSelector.cxx:50
Trk::MeasurementBaseType::RIO_OnTrack
@ RIO_OnTrack
Definition: MeasurementBase.h:49
fast
bool fast
Definition: TrigGlobEffCorrValidation.cxx:190
MuonPhiHitSelector::MuonPhiHitSelector
MuonPhiHitSelector(const std::string &, const std::string &, const IInterface *)
Definition: MuonPhiHitSelector.cxx:29
MuonPhiHitSelector::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonPhiHitSelector.h:37
MuonPhiHitSelector::clusterPhi
void clusterPhi(const std::vector< Identifier > &id, const std::vector< double > &hitx, const std::vector< double > &hity, const std::vector< double > &hitz, const std::vector< double > &error, const std::vector< double > &pull, std::vector< int > &select, const int n, std::vector< double > &clusterX, std::vector< double > &clusterY, std::vector< double > &clusterZ, std::vector< double > &clusterError, std::vector< Identifier > &clusterId, std::vector< int > &clusterHits, std::vector< int > &clusterSelect, std::vector< int > &clusterInt, int &ncl) const
clusterization method
Definition: MuonPhiHitSelector.cxx:302
IMuonHitSelector.h
MuonPhiHitSelector::m_summary
Gaudi::Property< bool > m_summary
flag to print out a summary of what comes in and what comes out
Definition: MuonPhiHitSelector.h:55
AthAlgTool
Definition: AthAlgTool.h:26
DerivationFramework::ClustersInCone::select
void select(const xAOD::IParticle *particle, const float coneSize, const xAOD::CaloClusterContainer *clusters, std::vector< bool > &mask)
Definition: ClustersInCone.cxx:14
error
Definition: IImpactPoint3dEstimator.h:70
IMuonIdHelperSvc.h
MuonPhiHitSelector::m_makeClusters
Gaudi::Property< bool > m_makeClusters
flag that performs a clusterization and return clusters (default: false)
Definition: MuonPhiHitSelector.h:59
ServiceHandle< Muon::IMuonIdHelperSvc >