 |
ATLAS Offline Software
|
Go to the documentation of this file.
19 const std::string& basePath,
23 auto createHisto = [stIndex, &
histSvc, &basePath](
const std::string& hName,
24 const std::string& hTitle,
28 TH1*
h =
new TH1F(hName.c_str(), hTitle.c_str(),
nBins, xLow, xHigh);
31 stIndex != StIdx_t::StUnknown ?
stName(stIndex) :
"Inclusive",
36 h_subID = createHisto(
"subDetId",
"Subdetector ID", 100, 0 , 150);
37 h_mrodID = createHisto(
"mrodID",
"MROD ID", 100, 0, 150);
38 h_csmID = createHisto(
"csmID",
"CSM ID", 100, 0, 10);
39 h_tdcID = createHisto(
"tdcID",
"TDC ID", 100, 0, 50);
40 h_chanID = createHisto(
"channelID",
"Channel ID", 100, 0, 50);
41 h_coarse = createHisto(
"coarseTime",
"Drift time (coarse)", 100, 0, 100);
42 h_fine = createHisto(
"fineTime",
"Drift time (fine)", 100, 0, 50);
43 h_width = createHisto(
"width",
"Width", 100, 0, 500);
54 for (
int s =
static_cast<int>(StIdx_t::StUnknown); s < static_cast<int>(StIdx_t::StIndexMax); ++
s) {
55 auto stIdx =
static_cast<StIdx_t>(
s);
59 return StatusCode::SUCCESS;
63 const EventContext& ctx{Gaudi::Hive::currentContext()};
67 for (
const MdtCsm* csm : *csmCont) {
68 std::vector<unsigned> fillMe{};
71 if (
m_histos[
h].stIdx == StIdx_t::StUnknown ||
75 const uint16_t subID = csm->SubDetId();
76 const uint16_t mrodID = csm->MrodId();
78 for (
unsigned h : fillMe) {
85 const uint16_t chanID = hit->channelId();
86 const uint16_t coarseTime = hit->coarse();
87 const uint16_t fineTime = hit->fine();
88 const uint16_t widthComb = hit->width();
89 for (
auto h : fillMe) {
99 return StatusCode::SUCCESS;
const ServiceHandle< ITHistSvc > & histSvc() const
The standard THistSvc (for writing histograms and TTrees and more to a root file) Returns (kind of) a...
MDT RDO's : data from a single channel of an AMT Atlas Muon TDC.
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Service handle of the IdHelperSvc.
const std::string & stName(StIndex index)
convert StIndex into a string
This container provides acces to the MDT RDOs.
MDT RDOs : Chamber Service Module, container of AmtHits of a single Mdt chamber.
virtual StatusCode execute() override final
Gaudi::Property< std::string > m_path
const T * get(const ReadCondHandleKey< T > &key, const EventContext &ctx)
Convenience function to retrieve an object given a ReadCondHandleKey.
::StatusCode StatusCode
StatusCode definition for legacy code.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
StIndex
enum to classify the different station layers in the muon spectrometer
Class to store array like branches into the n-tuples.
SG::ReadHandleKey< MdtCsmContainer > m_inputKey
Input read handle key.
HistoSet()=default
Default constructor.
virtual StatusCode initialize() override final
std::vector< HistoSet > m_histos
def TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)
Handle class for reading from StoreGate.