|
ATLAS Offline Software
|
#include <RPC_SimHitToPrdCBNTAlgo.h>
|
| RPC_SimHitToPrdCBNTAlgo (const std::string &name, ISvcLocator *pSvcLocator) |
|
| ~RPC_SimHitToPrdCBNTAlgo () |
|
virtual StatusCode | initialize () override |
|
virtual StatusCode | execute () override |
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
|
SG::ReadHandleKey< McEventCollection > | m_mcEvtKey {this, "mcEventKey", "TruthEvent"} |
|
SG::ReadHandleKey< RPCSimHitCollection > | m_HitCollKey {this, "HitCollectionName", "RPC_Hits"} |
|
SG::ReadHandleKey< RpcDigitContainer > | m_DigiCollKey {this, "DigitCollectionName", "RPC_DIGITS"} |
|
SG::ReadHandleKey< RpcPadContainer > | m_RDOKey {this, "RDOCollectionName", "RPCPAD"} |
|
SG::ReadHandleKey< Muon::RpcPrepDataContainer > | m_PrepKey {this, "PrdCollectionName", "RPC_Measurements"} |
|
|
const MuonGM::MuonDetectorManager * | m_muonMgr {nullptr} |
|
ServiceHandle< Muon::IMuonIdHelperSvc > | m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"} |
|
const RpcHitIdHelper * | m_muonHelper {nullptr} |
|
Gaudi::Property< bool > | m_doMCtruth {this, "doMCtruth", true} |
|
Gaudi::Property< bool > | m_doRPCSimHit {this, "doRPCSimHit", true} |
|
Gaudi::Property< bool > | m_doRPCDigit {this, "doRPCDigit", true} |
|
Gaudi::Property< bool > | m_doRPCRDO {this, "doRPCRDO", true} |
|
Gaudi::Property< bool > | m_doRPCPrep {this, "doRPCPrep", true} |
|
std::unique_ptr< Clockwork > | m_c |
|
DataObjIDColl | m_extendedExtraObjects |
|
StoreGateSvc_t | m_evtStore |
| Pointer to StoreGate (event store by default) More...
|
|
StoreGateSvc_t | m_detStore |
| Pointer to StoreGate (detector store by default) More...
|
|
std::vector< SG::VarHandleKeyArray * > | m_vhka |
|
bool | m_varHandleArraysDeclared |
|
Definition at line 27 of file RPC_SimHitToPrdCBNTAlgo.h.
◆ StoreGateSvc_t
◆ RPC_SimHitToPrdCBNTAlgo()
RPC_SimHitToPrdCBNTAlgo::RPC_SimHitToPrdCBNTAlgo |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~RPC_SimHitToPrdCBNTAlgo()
RPC_SimHitToPrdCBNTAlgo::~RPC_SimHitToPrdCBNTAlgo |
( |
| ) |
|
|
default |
◆ clearNTuple()
void RPC_SimHitToPrdCBNTAlgo::clearNTuple |
( |
| ) |
|
|
protected |
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ doMCtruth()
StatusCode RPC_SimHitToPrdCBNTAlgo::doMCtruth |
( |
const EventContext & |
ctx | ) |
|
|
private |
Definition at line 344 of file RPC_SimHitToPrdCBNTAlgo.cxx.
350 if (!mcEvent.isValid()) {
352 return StatusCode::FAILURE;
355 long eventCounter = 0;
358 for (
const HepMC::GenEvent*
e : (*mcEvent)) {
362 int particleCounter = 0;
363 for (
auto p : (*
e)) {
365 ATH_MSG_DEBUG(
"McEvent n. " << eventCounter <<
" particle # " << particleCounter);
366 if (ipart >= MAX_PART) {
367 ATH_MSG_WARNING(__FILE__ <<
":" << __LINE__ <<
" Number of particles exceeded. Please consider to increase MAX_PART:"
368 << MAX_PART <<
" at compile time");
376 float xv{-FLT_MAX}, yv{-FLT_MAX}, zv{-FLT_MAX}, tv{-FLT_MAX};
378 if (
p->production_vertex()) {
379 xv =
p->production_vertex()->position().x();
380 yv =
p->production_vertex()->position().y();
381 zv =
p->production_vertex()->position().z();
382 tv =
p->production_vertex()->position().t();
384 float xd =
p->momentum().px();
385 float yd =
p->momentum().py();
386 float zd =
p->momentum().pz();
387 float mag = std::hypot(
xd, yd, zd);
388 if (std::abs(
mag) > 0.001) {
389 direction[0] = (
xd /
mag);
390 direction[1] = (yd /
mag);
391 direction[2] = (zd /
mag);
395 float generatedMass =
p->generated_mass();
396 int pdgId =
p->pdg_id();
398 m_c->m_partVertX[ipart] = xv;
399 m_c->m_partVertY[ipart] = yv;
400 m_c->m_partVertZ[ipart] = zv;
401 m_c->m_partVertT[ipart] = tv;
402 m_c->m_partPdgId[ipart] = pdgId;
403 m_c->m_partMomX[ipart] =
xd;
404 m_c->m_partMomY[ipart] = yd;
405 m_c->m_partMomZ[ipart] = zd;
408 m_c->m_partMass[ipart] = generatedMass;
410 ATH_MSG_DEBUG(
"Event # " << eventCounter <<
" vertex at " << xv <<
" " << yv <<
" " << zv <<
" produced at time = " << tv
411 <<
" direction theta/eta/phi = " << direction.theta() <<
" " << direction.phi()
412 <<
" p = " << sqrt(
xd *
xd + yd * yd + zd * zd) <<
" pdgId = " << pdgId <<
" Status " <<
status);
415 m_c->m_npartStored = ipart;
417 return StatusCode::SUCCESS;
◆ doRPCDigit()
StatusCode RPC_SimHitToPrdCBNTAlgo::doRPCDigit |
( |
const EventContext & |
ctx | ) |
|
|
private |
Definition at line 527 of file RPC_SimHitToPrdCBNTAlgo.cxx.
531 ATH_MSG_DEBUG(
"RpcDigitContainer size: " << digitContainer->size());
532 if (!digitContainer.isValid()) {
534 return StatusCode::FAILURE;
540 if (myCounter >= MAX_DIGITRPC) {
541 ATH_MSG_WARNING(__FILE__ <<
":" << __LINE__ <<
" Cannot store more digits. Please consider to increase MAX_DIGITRPC:"
542 << MAX_DIGITRPC <<
" at compile time");
545 Identifier digit_id = (*rpcdigit)->identify();
547 m_c->m_digit_time[myCounter] = (*rpcdigit)->time();
549 m_c->m_digit_station[myCounter] =
m_idHelperSvc->rpcIdHelper().stationName(digit_id);
550 m_c->m_digit_eta[myCounter] =
m_idHelperSvc->rpcIdHelper().stationEta(digit_id);
551 m_c->m_digit_phi[myCounter] =
m_idHelperSvc->rpcIdHelper().stationPhi(digit_id);
552 m_c->m_digit_doubletR[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletR(digit_id);
553 m_c->m_digit_doubletZ[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletZ(digit_id);
554 m_c->m_digit_doubletPhi[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletPhi(digit_id);
555 m_c->m_digit_gasGap[myCounter] =
m_idHelperSvc->rpcIdHelper().gasGap(digit_id);
556 m_c->m_digit_measuresPhi[myCounter] =
m_idHelperSvc->rpcIdHelper().measuresPhi(digit_id);
557 m_c->m_digit_strip[myCounter] =
m_idHelperSvc->rpcIdHelper().strip(digit_id);
564 m_c->m_digit_stripx[myCounter] = stripPos.x();
565 m_c->m_digit_stripy[myCounter] = stripPos.y();
566 m_c->m_digit_stripz[myCounter] = stripPos.z();
568 ATH_MSG_DEBUG(
"DIG Station/eta/phi/dbR/dbZ/dbP/measPhi/strip: "
569 <<
m_c->m_digit_station[myCounter] <<
" " <<
m_c->m_digit_eta[myCounter] <<
" " <<
m_c->m_digit_phi[myCounter]
570 <<
" " <<
m_c->m_digit_doubletR[myCounter] <<
" " <<
m_c->m_digit_doubletZ[myCounter] <<
" "
571 <<
m_c->m_digit_doubletPhi[myCounter] <<
" " <<
m_c->m_digit_gasGap[myCounter] <<
" "
572 <<
m_c->m_digit_measuresPhi[myCounter] <<
" " <<
m_c->m_digit_strip[myCounter]);
577 m_c->m_digit_nRpcColl = digitContainer.cptr()->size();
578 m_c->m_digit_nRpc = myCounter;
579 ATH_MSG_DEBUG(
"Total n. of DIG / DIG collections " << myCounter <<
" " << digitContainer.cptr()->size());
582 return StatusCode::SUCCESS;
◆ doRPCPrep()
StatusCode RPC_SimHitToPrdCBNTAlgo::doRPCPrep |
( |
const EventContext & |
ctx | ) |
|
|
private |
Definition at line 681 of file RPC_SimHitToPrdCBNTAlgo.cxx.
685 if (!rpc_container.isValid()) {
687 return StatusCode::FAILURE;
689 int myCounter{0}, myCollCounter{0};
693 if (myCounter >= MAX_PRDRPC) {
694 ATH_MSG_WARNING(__FILE__ <<
":" << __LINE__ <<
" maximum prepdata exceeded. Please consider to retune MAX_PRDRPC="
695 << MAX_PRDRPC <<
" at compile time");
700 m_c->m_prd_time[myCounter] = (*rpcPrd)->time();
701 m_c->m_prd_station[myCounter] =
m_idHelperSvc->rpcIdHelper().stationName(prd_id);
702 m_c->m_prd_eta[myCounter] =
m_idHelperSvc->rpcIdHelper().stationEta(prd_id);
703 m_c->m_prd_phi[myCounter] =
m_idHelperSvc->rpcIdHelper().stationPhi(prd_id);
704 m_c->m_prd_doubletR[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletR(prd_id);
705 m_c->m_prd_doubletZ[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletZ(prd_id);
706 m_c->m_prd_doubletPhi[myCounter] =
m_idHelperSvc->rpcIdHelper().doubletPhi(prd_id);
708 m_c->m_prd_measuresPhi[myCounter] =
m_idHelperSvc->rpcIdHelper().measuresPhi(prd_id);
710 m_c->m_prd_triggerInfo[myCounter] = (*rpcPrd)->triggerInfo();
711 m_c->m_prd_ambigFlag[myCounter] = (*rpcPrd)->ambiguityFlag();
713 ATH_MSG_DEBUG(
"PRD Station/eta/phi/dbR/dbZ/dbP/measPhi/strip: "
714 <<
m_c->m_prd_station[myCounter] <<
" " <<
m_c->m_prd_eta[myCounter] <<
" " <<
m_c->m_prd_phi[myCounter] <<
" "
715 <<
m_c->m_prd_doubletR[myCounter] <<
" " <<
m_c->m_prd_doubletZ[myCounter] <<
" "
716 <<
m_c->m_prd_doubletPhi[myCounter] <<
" " <<
m_c->m_prd_gasGap[myCounter] <<
" "
717 <<
m_c->m_prd_measuresPhi[myCounter] <<
" " <<
m_c->m_prd_strip[myCounter]);
724 m_c->m_prd_stripx[myCounter] = stripPos.x();
725 m_c->m_prd_stripy[myCounter] = stripPos.y();
726 m_c->m_prd_stripz[myCounter] = stripPos.z();
733 m_c->m_nRpcPrd = myCounter;
734 m_c->m_nRpcColl = myCollCounter;
735 ATH_MSG_DEBUG(
"Total n. of PRD / PRD collections " << myCounter <<
" " << myCollCounter);
737 return StatusCode::SUCCESS;
◆ doRPCRDO()
StatusCode RPC_SimHitToPrdCBNTAlgo::doRPCRDO |
( |
const EventContext & |
ctx | ) |
|
|
private |
Definition at line 586 of file RPC_SimHitToPrdCBNTAlgo.cxx.
597 m_c->m_nFiredChannels = 0;
601 int myCounter{0}, myPadCounter{0}, myCMACounter{0};
602 for (
const RpcPad* rdoColl : *rpcRDO) {
604 if (myPadCounter >= MAX_PADRPC || myCounter >= MAX_RDOCHRPC) {
605 ATH_MSG_WARNING(__FILE__ <<
":" << __LINE__ <<
" Maximum pad is exceeded. Please consider to increase MAX_PADRPC=" << MAX_PADRPC
606 <<
" or MAX_RDOCHRPC=" << MAX_RDOCHRPC);
609 if (rdoColl->size()) {
613 m_c->m_rpc_pad_id[myPadCounter] = (
int)(rdoColl)->onlineId();
614 m_c->m_rpc_pad_sectorid[myPadCounter] = (
int)(rdoColl)->sector();
615 m_c->m_rpc_pad_error[myPadCounter] = (
int)(rdoColl)->errorCode();
616 m_c->m_rpc_pad_status[myPadCounter] = (
int)(rdoColl)->status();
618 m_c->m_rpc_pad_lvl1id[myPadCounter] = (
int)(rdoColl)->lvl1Id();
619 m_c->m_rpc_pad_bcid[myPadCounter] = (
int)(rdoColl)->bcId();
624 for (; it3 != it4; ++it3) {
625 ATH_MSG_DEBUG(
" Number of fired channels in this cma " << (*it3)->size());
631 for (; it5 != it6; ++it5) {
632 if (myCounter < MAX_RDOCHRPC) {
635 m_c->m_sector[myCounter] = (rdoColl)->sector();
636 m_c->m_padId[myCounter] = (rdoColl)->onlineId();
637 m_c->m_status[myCounter] = (rdoColl)->
status();
638 m_c->m_errorCode[myCounter] = (rdoColl)->errorCode();
640 m_c->m_fel1Id[myCounter] = cma->
fel1Id();
641 m_c->m_febcId[myCounter] = cma->
febcId();
642 m_c->m_crc[myCounter] = cma->
crc();
644 m_c->m_bcId[myCounter] = fChannel->
bcid();
645 m_c->m_time[myCounter] = fChannel->
time();
646 m_c->m_ijk[myCounter] = fChannel->
ijk();
647 m_c->m_channel[myCounter] = fChannel->
channel();
649 ATH_MSG_DEBUG(
"RDO sector/pad/cma/ijk/channel " <<
m_c->m_sector[myCounter] <<
" " <<
m_c->m_padId[myCounter] <<
" "
650 <<
m_c->m_cmaId[myCounter] <<
" " <<
m_c->m_ijk[myCounter] <<
" "
651 <<
m_c->m_channel[myCounter]);
652 if (fChannel->
ijk() == 7) {
653 m_c->m_overlap[myCounter] = fChannel->
ovl();
654 m_c->m_threshold[myCounter] = fChannel->
thr();
656 m_c->m_overlap[myCounter] = -1;
657 m_c->m_threshold[myCounter] = -1;
671 m_c->m_nFiredChannels = myCounter;
672 m_c->m_nCMA = myCMACounter;
673 m_c->m_nPads = myPadCounter;
677 return StatusCode::SUCCESS;
◆ doRPCSimHit()
StatusCode RPC_SimHitToPrdCBNTAlgo::doRPCSimHit |
( |
const EventContext & |
ctx | ) |
|
|
private |
Definition at line 421 of file RPC_SimHitToPrdCBNTAlgo.cxx.
427 if (!inputSimHitColl.isValid()) {
429 return StatusCode::FAILURE;
432 ATH_MSG_DEBUG(
"RPCSimHitCollection->size() : " << inputSimHitColl->size());
437 if (myCounter >= MAX_SIMHRPC) {
439 <<
"Maximum allowed number of simulated hits exceeded... Please consider to increase MAX_SIMHRPC="
440 << MAX_SIMHRPC <<
" at compile time");
443 const int idHit = rpcsimhit->RPCid();
445 int StationName = -1;
457 if (stationName_str ==
"BIL") {
459 }
else if (stationName_str ==
"BIS") {
461 }
else if (stationName_str ==
"BML") {
463 }
else if (stationName_str ==
"BMS") {
465 }
else if (stationName_str ==
"BOL") {
467 }
else if (stationName_str ==
"BOS") {
469 }
else if (stationName_str ==
"BIR") {
471 }
else if (stationName_str ==
"BMF") {
473 }
else if (stationName_str ==
"BOF") {
475 }
else if (stationName_str ==
"BOG") {
477 }
else if (stationName_str ==
"BIM") {
479 }
else if (stationName_str ==
"BME") {
481 }
else if (stationName_str ==
"BOE") {
487 <<
" stationName_str " << stationName_str <<
" stationEta " <<
stationEta <<
" stationPhi " <<
stationPhi
489 <<
" measphi " << measphi);
495 m_c->m_SimHit_time[myCounter] = rpcsimhit->globalTime();
496 m_c->m_SimHit_localx[myCounter] = rpcsimhit->localPosition().x();
497 m_c->m_SimHit_localy[myCounter] = rpcsimhit->localPosition().y();
498 m_c->m_SimHit_localz[myCounter] = rpcsimhit->localPosition().z();
499 m_c->m_SimHit_globalx[myCounter] =
gPos.x();
500 m_c->m_SimHit_globaly[myCounter] =
gPos.y();
501 m_c->m_SimHit_globalz[myCounter] =
gPos.z();
503 m_c->m_SimHit_station[myCounter] = StationName;
507 m_c->m_SimHit_doubletZ[myCounter] = doubletZ;
509 m_c->m_SimHit_gasGap[myCounter] =
gasGap;
510 m_c->m_SimHit_measuresPhi[myCounter] = measphi;
512 m_c->m_SimHit_truthBarcode[myCounter] = rpcsimhit->truthBarcode();
513 m_c->m_SimHit_stepLen[myCounter] = rpcsimhit->stepLength();
514 m_c->m_SimHit_energyDep[myCounter] = rpcsimhit->energyDeposit();
515 m_c->m_SimHit_kinEnergy[myCounter] = rpcsimhit->kineticEnergy();
516 m_c->m_SimHit_pdgId[myCounter] = rpcsimhit->particleEncoding();
521 m_c->m_SimHit_nRpc = myCounter;
523 return StatusCode::SUCCESS;
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode RPC_SimHitToPrdCBNTAlgo::execute |
( |
| ) |
|
|
overridevirtual |
Definition at line 318 of file RPC_SimHitToPrdCBNTAlgo.cxx.
323 const EventContext& ctx = Gaudi::Hive::currentContext();
324 m_c->event = ctx.eventID().event_number();
325 m_c->run = ctx.eventID().run_number();
330 return StatusCode::RECOVERABLE;
340 return StatusCode::SUCCESS;
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ extraOutputDeps()
const DataObjIDColl & AthAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 50 of file AthAlgorithm.cxx.
57 return Algorithm::extraOutputDeps();
◆ initialize()
StatusCode RPC_SimHitToPrdCBNTAlgo::initialize |
( |
| ) |
|
|
overridevirtual |
Definition at line 150 of file RPC_SimHitToPrdCBNTAlgo.cxx.
159 if (!
file)
return StatusCode::FAILURE;
161 NTuple::Directory*
col =
ntupleSvc()->createDirectory(
"/NTUPLES/FILE/RPCvalidNT");
163 NTuplePtr
nt(
ntupleSvc(),
"/NTUPLES/FILE/RPCvalidNT/RPC");
168 return StatusCode::FAILURE;
177 ATH_CHECK(
nt->addItem(
"NpartStored",
m_c->m_npartStored, 0, MAX_PART));
178 ATH_CHECK(
nt->addIndexedItem(
"partVertX",
m_c->m_npartStored,
m_c->m_partVertX));
179 ATH_CHECK(
nt->addIndexedItem(
"partVertY",
m_c->m_npartStored,
m_c->m_partVertY));
180 ATH_CHECK(
nt->addIndexedItem(
"partVertZ",
m_c->m_npartStored,
m_c->m_partVertZ));
181 ATH_CHECK(
nt->addIndexedItem(
"partVertT",
m_c->m_npartStored,
m_c->m_partVertT));
182 ATH_CHECK(
nt->addIndexedItem(
"partPdgId",
m_c->m_npartStored,
m_c->m_partPdgId));
186 ATH_CHECK(
nt->addIndexedItem(
"partStatus",
m_c->m_npartStored,
m_c->m_partStatus));
187 ATH_CHECK(
nt->addIndexedItem(
"partBarcode",
m_c->m_npartStored,
m_c->m_partBarcode));
193 ATH_CHECK(
nt->addItem(
"rpc_Nsimhit",
m_c->m_SimHit_nRpc, 0, MAX_SIMHRPC));
194 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_station",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_station));
195 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_eta",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_eta));
196 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_phi",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_phi));
197 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_doublr",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_doubletR));
198 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_doublz",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_doubletZ));
199 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_doublphi",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_doubletPhi));
200 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_gasgap",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_gasGap));
201 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_measphi",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_measuresPhi));
202 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_time",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_time));
203 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_localx",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_localx));
204 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_localy",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_localy));
205 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_localz",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_localz));
206 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_globalx",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_globalx));
207 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_globaly",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_globaly));
208 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_globalz",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_globalz));
209 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_truthBarcode",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_truthBarcode));
210 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_stepLen",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_stepLen));
211 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_energyDep",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_energyDep));
212 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_kinEnergy",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_kinEnergy));
213 ATH_CHECK(
nt->addIndexedItem(
"rpc_simhit_pdgId",
m_c->m_SimHit_nRpc,
m_c->m_SimHit_pdgId));
219 ATH_CHECK(
nt->addItem(
"rpc_Ndigit",
m_c->m_digit_nRpc, 0, MAX_DIGITRPC));
220 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_station",
m_c->m_digit_nRpc,
m_c->m_digit_station));
221 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_eta",
m_c->m_digit_nRpc,
m_c->m_digit_eta));
222 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_phi",
m_c->m_digit_nRpc,
m_c->m_digit_phi));
223 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_doublr",
m_c->m_digit_nRpc,
m_c->m_digit_doubletR));
224 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_doublz",
m_c->m_digit_nRpc,
m_c->m_digit_doubletZ));
225 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_doublphi",
m_c->m_digit_nRpc,
m_c->m_digit_doubletPhi));
226 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_gasgap",
m_c->m_digit_nRpc,
m_c->m_digit_gasGap));
227 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_measphi",
m_c->m_digit_nRpc,
m_c->m_digit_measuresPhi));
228 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_strip",
m_c->m_digit_nRpc,
m_c->m_digit_strip));
229 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_time",
m_c->m_digit_nRpc,
m_c->m_digit_time));
230 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_stripx",
m_c->m_digit_nRpc,
m_c->m_digit_stripx));
231 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_stripy",
m_c->m_digit_nRpc,
m_c->m_digit_stripy));
232 ATH_CHECK(
nt->addIndexedItem(
"rpc_digit_stripz",
m_c->m_digit_nRpc,
m_c->m_digit_stripz));
240 ATH_CHECK(
nt->addIndexedItem(
"rpc_pad_bcid",
m_c->m_nPads,
m_c->m_rpc_pad_bcid));
241 ATH_CHECK(
nt->addIndexedItem(
"rpc_pad_lvl1id",
m_c->m_nPads,
m_c->m_rpc_pad_lvl1id));
242 ATH_CHECK(
nt->addIndexedItem(
"rpc_pad_sectorid",
m_c->m_nPads,
m_c->m_rpc_pad_sectorid));
243 ATH_CHECK(
nt->addIndexedItem(
"rpc_pad_error",
m_c->m_nPads,
m_c->m_rpc_pad_error));
244 ATH_CHECK(
nt->addIndexedItem(
"rpc_pad_status",
m_c->m_nPads,
m_c->m_rpc_pad_status));
247 ATH_CHECK(
nt->addItem(
"rpc_Nrdo",
m_c->m_nFiredChannels, 0, MAX_RDOCHRPC));
248 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_sector",
m_c->m_nFiredChannels,
m_c->m_sector));
249 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_padId",
m_c->m_nFiredChannels,
m_c->m_padId));
250 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_status",
m_c->m_nFiredChannels,
m_c->m_status));
251 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_errcode",
m_c->m_nFiredChannels,
m_c->m_errorCode));
252 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_cmaId",
m_c->m_nFiredChannels,
m_c->m_cmaId));
253 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_fel1Id",
m_c->m_nFiredChannels,
m_c->m_fel1Id));
254 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_febcId",
m_c->m_nFiredChannels,
m_c->m_febcId));
256 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_bcId",
m_c->m_nFiredChannels,
m_c->m_bcId));
257 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_ticks",
m_c->m_nFiredChannels,
m_c->m_time));
259 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_cmachan",
m_c->m_nFiredChannels,
m_c->m_channel));
260 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_overlap",
m_c->m_nFiredChannels,
m_c->m_overlap));
261 ATH_CHECK(
nt->addIndexedItem(
"rpc_rdo_threshold",
m_c->m_nFiredChannels,
m_c->m_threshold));
268 ATH_CHECK(
nt->addItem(
"rpc_Nprd",
m_c->m_nRpcPrd, 0, MAX_PRDRPC));
269 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_station",
m_c->m_nRpcPrd,
m_c->m_prd_station));
272 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_doublr",
m_c->m_nRpcPrd,
m_c->m_prd_doubletR));
273 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_doublz",
m_c->m_nRpcPrd,
m_c->m_prd_doubletZ));
274 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_doublphi",
m_c->m_nRpcPrd,
m_c->m_prd_doubletPhi));
275 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_gasgap",
m_c->m_nRpcPrd,
m_c->m_prd_gasGap));
276 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_measphi",
m_c->m_nRpcPrd,
m_c->m_prd_measuresPhi));
277 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_strip",
m_c->m_nRpcPrd,
m_c->m_prd_strip));
279 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_stripx",
m_c->m_nRpcPrd,
m_c->m_prd_stripx));
280 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_stripy",
m_c->m_nRpcPrd,
m_c->m_prd_stripy));
281 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_stripz",
m_c->m_nRpcPrd,
m_c->m_prd_stripz));
282 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_triggerInfo",
m_c->m_nRpcPrd,
m_c->m_prd_triggerInfo));
283 ATH_CHECK(
nt->addIndexedItem(
"rpc_prd_ambigFlag",
m_c->m_nRpcPrd,
m_c->m_prd_ambigFlag));
287 return StatusCode::SUCCESS;
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_c
std::unique_ptr<Clockwork> RPC_SimHitToPrdCBNTAlgo::m_c |
|
private |
◆ m_detStore
◆ m_DigiCollKey
◆ m_doMCtruth
Gaudi::Property<bool> RPC_SimHitToPrdCBNTAlgo::m_doMCtruth {this, "doMCtruth", true} |
|
private |
◆ m_doRPCDigit
Gaudi::Property<bool> RPC_SimHitToPrdCBNTAlgo::m_doRPCDigit {this, "doRPCDigit", true} |
|
private |
◆ m_doRPCPrep
Gaudi::Property<bool> RPC_SimHitToPrdCBNTAlgo::m_doRPCPrep {this, "doRPCPrep", true} |
|
private |
◆ m_doRPCRDO
Gaudi::Property<bool> RPC_SimHitToPrdCBNTAlgo::m_doRPCRDO {this, "doRPCRDO", true} |
|
private |
◆ m_doRPCSimHit
Gaudi::Property<bool> RPC_SimHitToPrdCBNTAlgo::m_doRPCSimHit {this, "doRPCSimHit", true} |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_HitCollKey
◆ m_idHelperSvc
◆ m_mcEvtKey
◆ m_muonHelper
◆ m_muonMgr
◆ m_PrepKey
◆ m_RDOKey
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
const RpcReadoutElement * getRpcReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
std::string GetStationName(const int &hid) const
const MuonGM::MuonDetectorManager * m_muonMgr
constexpr uint8_t stationPhi
station Phi 1 to 8
static const RpcHitIdHelper * GetHelper(unsigned int nGasGaps=2)
Const iterator class for DataVector/DataList.
int GetDoubletPhi(const int &hid) const
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Gaudi::Property< bool > m_doRPCRDO
int GetMeasuresPhi(const int &hid) const
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
StatusCode doRPCSimHit(const EventContext &ctx)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
SG::ReadHandleKey< McEventCollection > m_mcEvtKey
int GetDoubletZ(const int &hid) const
Gaudi::Property< bool > m_doRPCDigit
An RpcReadoutElement corresponds to a single RPC module; therefore typicaly a barrel muon station con...
StatusCode doRPCRDO(const EventContext &ctx)
Gaudi::Property< bool > m_doRPCSimHit
CONT::const_iterator const_iterator
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
SG::ReadHandleKey< RpcDigitContainer > m_DigiCollKey
StatusCode doRPCDigit(const EventContext &ctx)
int GetPhiSector(const int &hid) const
Gaudi::Property< bool > m_doMCtruth
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
::StatusCode StatusCode
StatusCode definition for legacy code.
const RpcHitIdHelper * m_muonHelper
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
SG::ReadHandleKey< RpcPadContainer > m_RDOKey
StatusCode doRPCPrep(const EventContext &ctx)
int GetGasGapLayer(const int &hid) const
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
StatusCode doMCtruth(const EventContext &ctx)
Amg::Vector3D stripPos(const Identifier &id) const
SG::ReadHandleKey< Muon::RpcPrepDataContainer > m_PrepKey
Eigen::Matrix< double, 3, 1 > Vector3D
DataObjIDColl m_extendedExtraObjects
int GetDoubletR(const int &hid) const
std::unique_ptr< Clockwork > m_c
#define ATH_MSG_WARNING(x)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
SG::ReadHandleKey< RPCSimHitCollection > m_HitCollKey
AthAlgorithm()
Default constructor:
constexpr uint8_t stationEta
1 to 3
Gaudi::Property< bool > m_doRPCPrep
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Scalar mag() const
mag method
int GetZSector(const int &hid) const