ATLAS Offline Software
CSCSegmValMonAlg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef CSCSegmValMonAlg_H
6 #define CSCSegmValMonAlg_H
7 
11 
12 #include "GaudiKernel/ServiceHandle.h"
13 #include "GaudiKernel/ToolHandle.h"
14 
17 #include "TrkTrack/Track.h"
18 
23 
24 #include <vector>
25 #include <string>
26 
27 namespace Trk {
28  class MeasurementBase;
29 }
30 
32 
33  public:
35  CSCSegmValMonAlg( const std::string& name, ISvcLocator* pSvcLocator );
37  virtual ~CSCSegmValMonAlg()=default;
38  virtual StatusCode initialize() override;
39  virtual StatusCode fillHistograms( const EventContext& ctx ) const override;
40 
41  private:
42 
43  typedef std::vector<TH1 *> SegmHistType;
44  typedef std::vector<TH1 *>::const_iterator SegmHistIter;
45 
46  typedef std::vector<const Trk::MeasurementBase*> TrkSegmType;
47  typedef std::vector<const Trk::MeasurementBase*>::const_iterator TrkSegmIter;
48 
49  typedef enum EndCaps { ECA = 0, ECC } EndCapType;
50 
51  bool isCscSegment( const Muon::MuonSegment* seg ) const;
52  unsigned int cscHits( const Muon::MuonSegment* seg ) const;
53  bool segmSlopeCut(const float csc_x, const float csc_ax, const float cut ) const;
54  //Trigger aware monitoring
55  bool evtSelTriggersPassed() const;
56 
58  "Muon::MuonEDMHelperSvc/MuonEDMHelperSvc",
59  "Handle to the service providing the IMuonEDMHelperSvc interface" };
60  ServiceHandle<Muon::IMuonIdHelperSvc> m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
61  SG::ReadHandleKeyArray<Trk::SegmentCollection> m_segmKey{this,"SegmentKey",{"TrkMuonSegments", "UnAssocMuonTrkSegments"},"muon segments"};
62 
63  Gaudi::Property<std::vector<std::string>> m_sampSelTriggers{this,"EventSelTriggers",{}};
64  Gaudi::Property<bool> m_doEvtSel{this,"DoEventSelection",false};
65  Gaudi::Property<double> m_segmSlope{this,"SegmentSlopeCut",0};
66 
67 };
68 
69 #endif
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
CSCSegmValMonAlg::~CSCSegmValMonAlg
virtual ~CSCSegmValMonAlg()=default
Destructor.
CSCSegmValMonAlg::ECA
@ ECA
Definition: CSCSegmValMonAlg.h:49
CSCSegmValMonAlg::ECC
@ ECC
Definition: CSCSegmValMonAlg.h:49
CSCSegmValMonAlg::SegmHistType
std::vector< TH1 * > SegmHistType
Definition: CSCSegmValMonAlg.h:43
CSCSegmValMonAlg::TrkSegmType
std::vector< const Trk::MeasurementBase * > TrkSegmType
Definition: CSCSegmValMonAlg.h:46
CSCSegmValMonAlg::TrkSegmIter
std::vector< const Trk::MeasurementBase * >::const_iterator TrkSegmIter
Definition: CSCSegmValMonAlg.h:47
CSCSegmValMonAlg::EndCaps
EndCaps
Definition: CSCSegmValMonAlg.h:49
CSCSegmValMonAlg::isCscSegment
bool isCscSegment(const Muon::MuonSegment *seg) const
Definition: CSCSegmValMonAlg.cxx:490
SG::HandleKeyArray
Definition: StoreGate/StoreGate/HandleKeyArray.h:38
TrigDecisionTool.h
CSCSegmValMonAlg::CSCSegmValMonAlg
CSCSegmValMonAlg(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Definition: CSCSegmValMonAlg.cxx:28
CSCSegmValMonAlg
Definition: CSCSegmValMonAlg.h:31
CSCSegmValMonAlg::SegmHistIter
std::vector< TH1 * >::const_iterator SegmHistIter
Definition: CSCSegmValMonAlg.h:44
CSCSegmValMonAlg::fillHistograms
virtual StatusCode fillHistograms(const EventContext &ctx) const override
adds event to the monitoring histograms
Definition: CSCSegmValMonAlg.cxx:57
Track.h
AthMonitorAlgorithm
Base class for Athena Monitoring Algorithms.
Definition: AthMonitorAlgorithm.h:36
CSCSegmValMonAlg::m_edmHelperSvc
ServiceHandle< Muon::IMuonEDMHelperSvc > m_edmHelperSvc
Definition: CSCSegmValMonAlg.h:57
ManagedMonitorToolBase.h
CSCSegmValMonAlg::cscHits
unsigned int cscHits(const Muon::MuonSegment *seg) const
Definition: CSCSegmValMonAlg.cxx:512
CSCSegmValMonAlg::m_doEvtSel
Gaudi::Property< bool > m_doEvtSel
Definition: CSCSegmValMonAlg.h:64
CSCSegmValMonAlg::initialize
virtual StatusCode initialize() override
initialize
Definition: CSCSegmValMonAlg.cxx:34
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthMonitorAlgorithm.h
BindingsTest.cut
cut
This script demonstrates how to call a C++ class from Python Also how to use PyROOT is shown.
Definition: BindingsTest.py:13
CSCSegmValMonAlg::m_segmKey
SG::ReadHandleKeyArray< Trk::SegmentCollection > m_segmKey
Definition: CSCSegmValMonAlg.h:61
Monitored.h
Header file to be included by clients of the Monitored infrastructure.
CSCSegmValMonAlg::m_sampSelTriggers
Gaudi::Property< std::vector< std::string > > m_sampSelTriggers
Definition: CSCSegmValMonAlg.h:63
IMuonEDMHelperSvc.h
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
CSCSegmValMonAlg::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: CSCSegmValMonAlg.h:60
CSCSegmValMonAlg::evtSelTriggersPassed
bool evtSelTriggersPassed() const
Definition: CSCSegmValMonAlg.cxx:476
CSCSegmValMonAlg::EndCapType
enum CSCSegmValMonAlg::EndCaps EndCapType
CSCSegmValMonAlg::segmSlopeCut
bool segmSlopeCut(const float csc_x, const float csc_ax, const float cut) const
Definition: CSCSegmValMonAlg.cxx:533
MuonSegment.h
CSCSegmValMonAlg::m_segmSlope
Gaudi::Property< double > m_segmSlope
Definition: CSCSegmValMonAlg.h:65
Muon::MuonSegment
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:45
IMuonIdHelperSvc.h
SegmentCollection.h
ServiceHandle< Muon::IMuonEDMHelperSvc >