ATLAS Offline Software
Loading...
Searching...
No Matches
Athena::RootNtupleEventSelector Class Reference

Class implementing the GAUDI IEvtSelector interface using ROOT TTree as a backend. More...

#include <RootNtupleEventSelector.h>

Inheritance diagram for Athena::RootNtupleEventSelector:
Collaboration diagram for Athena::RootNtupleEventSelector:

Classes

Public Member Functions

 RootNtupleEventSelector (const std::string &name, ISvcLocator *svcLoc)
 Constructor with parameters:
virtual ~RootNtupleEventSelector ()
 Destructor:
virtual StatusCode initialize () override
virtual StatusCode finalize () override
virtual void handle (const Incident &incident) override
virtual StatusCode io_reinit () override
 Callback method to reinitialize the internal state of the component for I/O purposes (e.g.
virtual int size (Context &refCtxt) const override
 ICollectionSize interface
virtual StatusCode createContext (Context *&refpCtxt) const override
virtual StatusCode last (Context &refContext) const override
virtual StatusCode next (Context &refCtxt) const override
virtual StatusCode next (Context &refCtxt, int jump) const override
virtual StatusCode previous (Context &refCtxt) const override
virtual StatusCode previous (Context &refCtxt, int jump) const override
virtual StatusCode rewind (Context &refCtxt) const override
virtual StatusCode createAddress (const Context &refCtxt, IOpaqueAddress *&) const override
virtual StatusCode releaseContext (Context *&refCtxt) const override
virtual StatusCode resetCriteria (const std::string &cr, Context &ctx) const override
virtual StatusCode seek (Context &refCtxt, int evtnum) const override
 Seek to a given event number.
virtual int curEvent (const Context &refCtxt) const override
 return the current event number.
virtual StatusCode preLoadAddresses (StoreID::type storeID, tadList &list) override
 IAddressProvider interface get all addresses from Provider : Called before Begin Event
virtual StatusCode loadAddresses (StoreID::type storeID, tadList &list) override
 get all new addresses from Provider for this Event.
virtual StatusCode updateAddress (StoreID::type storeID, SG::TransientAddress *tad, const EventContext &ctx) override
 update a transient Address

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
typedef ServiceHandle< IClassIDSvc > ICLIDSvc_t
typedef ServiceHandle< IDictLoaderSvcIDictSvc_t
typedef ServiceHandle< IIncidentSvc > IIncSvc_t

Private Member Functions

StatusCode endInputFile (RootNtupleEventContext *rctx) const
void setupInputCollection (Gaudi::Details::PropertyBase &inputCollectionsName)
 callback to synchronize the list of input files
StatusCode createRootBranchAddresses (StoreID::type storeID, tadList &tads)
 helper method to create proxies
TTree * fetchNtuple (const std::string &fname, const std::string &tupleName) const
 helper method to retrieve the correct tuple
void addMetadataFromDirectoryName (const std::string &metadirname, TFile *fileObj, const std::string &prefix="") const
void addMetadataFromDirectory (TDirectoryFile *metadir, const std::string &prefix="") const
void addMetadata (TTree *metatree, const std::string &path="") const
void addMetadata (TObjString *metastring, const std::string &path="") const
StatusCode createMetaDataRootBranchAddresses (StoreGateSvc *store, TTree *tree, const std::string &prefix) const
 helper method to create proxies for the metadata store
StatusCode do_init_io ()
 helper method to init the i/o components
void find_coll_idx (int evtidx, long &coll_idx, long &tuple_idx) const
 helper method to get the collection index (into m_inputCollectionsName) and tuple index (into ‘m_tupleNames’) / for a given event index evtidx.
RootNtupleEventSelectorself () const
 non-const access to self (b/c next() is const)

Private Attributes

StoreGateSvc_t m_dataStore
 Pointer to the StoreGateSvc event store.
StoreGateSvc_t m_imetaStore
 Pointer to the StoreGateSvc input metadata store.
StoreGateSvc_t m_ometaStore
 Pointer to the StoreGateSvc output metadata store.
ICLIDSvc_t m_clidsvc
 Pointer to the IClassIDSvc.
IDictSvc_t m_dictsvc
 Pointer to the IDictLoaderSvc.
IIncSvc_t m_incsvc
 Handle to the incident service.
StringArrayProperty m_inputCollectionsName
 List of input files containing TTree.
StringProperty m_tupleName
 Name of TTree to load from collection of input files.
StringArrayProperty m_activeBranchNames
 List of branches to activate in the TTree.
long m_skipEvts
 Number of events to skip at the beginning.
std::vector< std::string > m_tupleNames
 Names of all trees over which to iterate.
long m_nbrEvts
 Number of Events read so far.
long m_curEvt
 current event index
std::vector< std::vector< CollMetaData > > m_collEvts
 cache of the number of entries for each collection Indexed like [tuple][collection]
TTree * m_tuple
 current tree being read
bool m_needReload
 The (python) selection function to apply on the TChain we are reading.
bool m_fireBIF
std::vector< TFile * > m_files

Friends

class Athena::RootNtupleEventContext

Detailed Description

Class implementing the GAUDI IEvtSelector interface using ROOT TTree as a backend.

Definition at line 45 of file RootNtupleEventSelector.h.

Member Typedef Documentation

◆ ICLIDSvc_t

Definition at line 195 of file RootNtupleEventSelector.h.

◆ IDictSvc_t

◆ IIncSvc_t

Definition at line 203 of file RootNtupleEventSelector.h.

◆ StoreGateSvc_t

Constructor & Destructor Documentation

◆ RootNtupleEventSelector()

Athena::RootNtupleEventSelector::RootNtupleEventSelector ( const std::string & name,
ISvcLocator * svcLoc )

Constructor with parameters:

Definition at line 222 of file RootNtupleEventSelector.cxx.

223 :
224 extends ( name, svcLoc ),
225 m_dataStore( "StoreGateSvc/StoreGateSvc", name ),
226 m_imetaStore( "StoreGateSvc/InputMetaDataStore", name ),
227 m_ometaStore( "StoreGateSvc/MetaDataStore", name ),
228 m_clidsvc ( "ClassIDSvc", name ),
229 m_dictsvc ( "AthDictLoaderSvc", name ),
230 m_incsvc ( "IncidentSvc", name ),
231 m_nbrEvts ( 0 ),
232 m_curEvt ( 0 ),
233 m_collEvts ( ),
234 m_tuple (NULL),
235 m_needReload (true),
236 m_fireBIF (true)
237{
238 declareProperty( "DataStore",
240 "Store where to publish data");
241
242 declareProperty( "InputMetaStore",
244 "Store where to publish (input) metadata");
245
246 declareProperty( "MetaStore",
248 "Store where to publish (output) metadata");
249
250 declareProperty( "InputCollections",
252 "List of input (ROOT) file names" );
253 m_inputCollectionsName.declareUpdateHandler
255
256 declareProperty( "TupleName",
257 m_tupleName = "CollectionTree",
258 "Name of the TTree to load/read from input file(s). "
259 "May be a semicolon-separated string to read multiple TTrees.");
260
261 declareProperty( "SkipEvents",
262 m_skipEvts = 0,
263 "Number of events to skip at the beginning" );
264
265 declareProperty( "ActiveBranches",
267 "List of branch names to activate" );
268}
void setupInputCollection(Gaudi::Details::PropertyBase &inputCollectionsName)
callback to synchronize the list of input files
StringArrayProperty m_activeBranchNames
List of branches to activate in the TTree.
TTree * m_tuple
current tree being read
std::vector< std::vector< CollMetaData > > m_collEvts
cache of the number of entries for each collection Indexed like [tuple][collection]
bool m_needReload
The (python) selection function to apply on the TChain we are reading.
IDictSvc_t m_dictsvc
Pointer to the IDictLoaderSvc.
StoreGateSvc_t m_imetaStore
Pointer to the StoreGateSvc input metadata store.
IIncSvc_t m_incsvc
Handle to the incident service.
StringArrayProperty m_inputCollectionsName
List of input files containing TTree.
ICLIDSvc_t m_clidsvc
Pointer to the IClassIDSvc.
StringProperty m_tupleName
Name of TTree to load from collection of input files.
StoreGateSvc_t m_dataStore
Pointer to the StoreGateSvc event store.
StoreGateSvc_t m_ometaStore
Pointer to the StoreGateSvc output metadata store.
long m_skipEvts
Number of events to skip at the beginning.
long m_nbrEvts
Number of Events read so far.

◆ ~RootNtupleEventSelector()

Athena::RootNtupleEventSelector::~RootNtupleEventSelector ( )
virtual

Destructor:

Definition at line 272 of file RootNtupleEventSelector.cxx.

273{}

Member Function Documentation

◆ addMetadata() [1/2]

void Athena::RootNtupleEventSelector::addMetadata ( TObjString * metastring,
const std::string & path = "" ) const
private

Definition at line 1179 of file RootNtupleEventSelector.cxx.

1180{
1181 std::string *converted = new std::string(metastring->String());
1182 if (!m_imetaStore->record(converted, path).isSuccess()) {
1183 ATH_MSG_INFO("Could not create metadata for string [" << path << "]");
1184 }
1185}
#define ATH_MSG_INFO(x)

◆ addMetadata() [2/2]

void Athena::RootNtupleEventSelector::addMetadata ( TTree * metatree,
const std::string & path = "" ) const
private

Definition at line 1167 of file RootNtupleEventSelector.cxx.

1168{
1169 if (metatree->GetEntry(0) < 0) {
1170 ATH_MSG_INFO("Problem retrieving data from metadata-tree [" << path << "] !!");
1171 return;
1172 }
1173
1174 if (!createMetaDataRootBranchAddresses(m_imetaStore.get(), metatree, path).isSuccess()) {
1175 ATH_MSG_INFO("Could not create metadata for tree [" << path << "]");
1176 }
1177}
StatusCode createMetaDataRootBranchAddresses(StoreGateSvc *store, TTree *tree, const std::string &prefix) const
helper method to create proxies for the metadata store

◆ addMetadataFromDirectory()

void Athena::RootNtupleEventSelector::addMetadataFromDirectory ( TDirectoryFile * metadir,
const std::string & prefix = "" ) const
private

Definition at line 1125 of file RootNtupleEventSelector.cxx.

1126{
1127 std::unordered_set<std::string> meta_keys;
1128 const TList *keys = metadir->GetListOfKeys();
1129 for (Int_t i=0; i < keys->GetSize(); ++i) {
1130 TKey* key = dynamic_cast<TKey*>(keys->At(i));
1131 if (!key) {
1132 continue;
1133 }
1134
1135 const std::string meta_key = key->GetName();
1136 if (!meta_keys.emplace(key->GetName()).second) {
1137 // key was already in the set:
1138 // meta_key is another cycle from a previous key entry.
1139 // *ASSUME* the highest cycle is the one we are interested in
1140 // *AND* that it was the previous one...
1141 continue;
1142 }
1143
1144 std::string fullPrefix(prefix);
1145 if (prefix != "") fullPrefix += "/";
1146 const std::string path = fullPrefix + key->GetName();
1147
1148 TString fullKeyName(TString::Format("%s;%hi", key->GetName(), key->GetCycle()));
1149 TObject *objRef = metadir->Get(fullKeyName);
1150
1151 TTree *metatree = dynamic_cast<TTree*>(objRef);
1152 if (metatree) {
1153 addMetadata(metatree, path);
1154 continue;
1155 }
1156
1157 TObjString *metaObjString = dynamic_cast<TObjString*>(objRef);
1158 if (metaObjString) {
1159 addMetadata(metaObjString, path);
1160 continue;
1161 }
1162
1163 ATH_MSG_WARNING("Unsupported metadata type: " << objRef->ClassName());
1164 }
1165}
#define ATH_MSG_WARNING(x)
void addMetadata(TTree *metatree, const std::string &path="") const
path
python interpreter configuration --------------------------------------—
Definition athena.py:128

◆ addMetadataFromDirectoryName()

void Athena::RootNtupleEventSelector::addMetadataFromDirectoryName ( const std::string & metadirname,
TFile * fileObj,
const std::string & prefix = "" ) const
private

Definition at line 1118 of file RootNtupleEventSelector.cxx.

1119{
1120 TDirectoryFile *metadir = (TDirectoryFile*)fileObj->Get(metadirname.c_str());
1121 if (!metadir) return;
1122 addMetadataFromDirectory(metadir, prefix);
1123}
void addMetadataFromDirectory(TDirectoryFile *metadir, const std::string &prefix="") const

◆ createAddress()

StatusCode Athena::RootNtupleEventSelector::createAddress ( const Context & refCtxt,
IOpaqueAddress *&  ) const
overridevirtual

Definition at line 639 of file RootNtupleEventSelector.cxx.

641{
642 //std::cerr << "::TTES::createAddress()...\n";
643 return StatusCode::SUCCESS;
644}

◆ createContext()

StatusCode Athena::RootNtupleEventSelector::createContext ( Context *& refpCtxt) const
overridevirtual

IEvtSelector interface

Definition at line 631 of file RootNtupleEventSelector.cxx.

632{
634 refCtx = ctx;
635 return StatusCode::SUCCESS;
636}

◆ createMetaDataRootBranchAddresses()

StatusCode Athena::RootNtupleEventSelector::createMetaDataRootBranchAddresses ( StoreGateSvc * store,
TTree * tree,
const std::string & prefix ) const
private

helper method to create proxies for the metadata store

Definition at line 952 of file RootNtupleEventSelector.cxx.

955{
956 if (0 == store) {
957 ATH_MSG_ERROR("null pointer to store !");
958 return StatusCode::FAILURE;
959 }
960
961 if (0 == tree) {
962 ATH_MSG_ERROR("null pointer to n-tuple !");
963 return StatusCode::FAILURE;
964 }
965
966 // Record tree in Storegate for later writing
967 TransferTree* temp = new TransferTree(tree);
968 if (store->record(temp,prefix).isFailure()) ATH_MSG_ERROR("Unable to record metadata tree " << tree->GetName());
969
970 const std::string tree_name = tree->GetName();
971 TObjArray *branches = tree->GetListOfBranches();
972 if (!branches) {
973 ATH_MSG_INFO("no branches!!");
974 return StatusCode::SUCCESS;
975 }
976
977 // loop over branches
978 for (Int_t i = 0; i < branches->GetEntries(); ++i) {
979 TBranch *branch = (TBranch *)branches->At(i);
980 if (branch) {
981
982 CLID id = 0;
983 const void* value_ptr = tree;
984 const std::string type_name = branch->GetClassName();
985 const std::string br_name = branch->GetName();
986 const std::string sg_key = prefix.empty()
987 ? br_name
988 : prefix + "/" + br_name;
989 TClass *cls = NULL;
990 if (!type_name.empty()) {
991 cls = TClass::GetClass(type_name.c_str());
992 }
993 const std::type_info *ti = 0;
994
995 if (cls) {
996 ti = cls->GetTypeInfo();
997 // first, try to load a dict for that class...
998 if (ti) {
999 m_dictsvc->load_type(*ti);
1000 }
1001 if (!ti) {
1002 ATH_MSG_WARNING("could not find a type-info for [" <<
1003 type_name << "]");
1004 continue;
1005 }
1006 std::string ti_typename = System::typeinfoName(*ti);
1007 if (!m_clidsvc->getIDOfTypeInfoName(ti_typename, id)
1008 .isSuccess()) {
1009 // try another one...
1010 {
1011 // Protect against data race inside TClassEdit.
1012 // https://github.com/root-project/root/issues/10353
1013 // Should be fixed in root 6.26.02.
1014 R__WRITE_LOCKGUARD(ROOT::gCoreMutex);
1015 ti_typename = TClassEdit::ShortType(ti_typename.c_str(),
1016 TClassEdit::kDropAllDefault);
1017 }
1018 if (!m_clidsvc->getIDOfTypeInfoName(ti_typename, id)
1019 .isSuccess()) {
1020 ATH_MSG_INFO("** could not find a CLID from type-info ["
1021 << System::typeinfoName(*ti) << "]");
1022 ATH_MSG_INFO("** could not find a CLID from type-info-alias ["
1023 << ti_typename << "]");
1024 continue;
1025 }
1026 }
1027 } else {
1028 // probably a built-in type...
1029 TObjArray *leaves = branch->GetListOfLeaves();
1030 if (leaves &&
1031 leaves->GetEntries() == 1) {
1032 const std::string type_name = ((TLeaf*)leaves->At(0))->GetTypeName();
1033 if (!m_clidsvc->getIDOfTypeName(::root_typename(type_name), id)
1034 .isSuccess()) {
1035 ATH_MSG_INFO("** could not find a CLID for type-name ["
1036 << type_name << "]");
1037 continue;
1038 }
1039 }
1040 }
1041 if (id == 0) {
1042 ATH_MSG_INFO("** could not find a CLID for type-name ["
1043 << type_name << "]");
1044 continue;
1045 }
1046 CxxUtils::RefCountedPtr<Athena::RootBranchAddress> addr
1047 (new Athena::RootBranchAddress
1048 (ROOT_StorageType, id,
1049 tree_name,
1050 br_name,
1051 (unsigned long)(value_ptr),
1052 (unsigned long)(0)));
1053 if (!store->recordAddress(sg_key, std::move(addr), true).isSuccess()) {
1054 ATH_MSG_ERROR("could not record address at [" << sg_key << "] in store ["
1055 << store->name() << "]");
1056 }
1057 // SG::TransientAddress* taddr = new SG::TransientAddress
1058 // (id, sg_key, addr);
1059 // taddr->setProvider(this);
1060 // taddr->clearAddress(true);
1061 // tads.push_back(taddr);
1062 }
1063 }
1064 return StatusCode::SUCCESS;
1065}
#define ATH_MSG_ERROR(x)
uint32_t CLID
The Class ID type.
void record(const T *p, const std::string &key)
Definition TestStore.h:81
virtual const std::string & name() const override
Definition TestStore.cxx:97
TestStore store
Definition TestStore.cxx:23
TChain * tree

◆ createRootBranchAddresses()

StatusCode Athena::RootNtupleEventSelector::createRootBranchAddresses ( StoreID::type storeID,
tadList & tads )
private

helper method to create proxies

Definition at line 839 of file RootNtupleEventSelector.cxx.

841{
842 if (storeID != StoreID::EVENT_STORE) {
843 ATH_MSG_INFO("-- not the event-store --");
844 return(StatusCode::SUCCESS);
845 }
846
847 if (0 == m_tuple) {
848 ATH_MSG_ERROR("null pointer to n-tuple !");
849 return StatusCode::FAILURE;
850 }
851
852 TObjArray *leaves = m_tuple->GetListOfLeaves();
853 if (!leaves) {
854 ATH_MSG_INFO("no leaves!!");
855 return StatusCode::SUCCESS;
856 }
857
858 // loop over leaves
859 for (Int_t i = 0; i < leaves->GetEntries(); ++i) {
860 TLeaf *leaf = (TLeaf *)leaves->At(i);
861 TBranch *branch = leaf->GetBranch();
862 if (branch) {
863
864 CLID id = 0;
865 const void* value_ptr = m_tuple;
866 const std::string type_name = leaf->GetTypeName();
867 const std::string br_name = branch->GetName();
868 const std::string sg_key = br_name;//m_tupleName.value()+"/"+br_name;
869 TClass *cls = TClass::GetClass(type_name.c_str());
870 const std::type_info *ti = 0;
871
872 if (cls) {
873 ti = cls->GetTypeInfo();
874 // first, try to load a dict for that class...
875 if (ti) {
876 m_dictsvc->load_type(*ti);
877 }
878 if (!ti) {
879 ATH_MSG_WARNING("could not find a type-info for [" <<
880 type_name << "]");
881 continue;
882 }
883 std::string ti_typename = System::typeinfoName(*ti);
884 if (!m_clidsvc->getIDOfTypeInfoName(ti_typename, id)
885 .isSuccess()) {
886 // try another one...
887 {
888 // Protect against data race inside TClassEdit.
889 // https://github.com/root-project/root/issues/10353
890 // Should be fixed in root 6.26.02.
891 R__WRITE_LOCKGUARD(ROOT::gCoreMutex);
892 ti_typename = TClassEdit::ShortType(ti_typename.c_str(),
893 TClassEdit::kDropAllDefault);
894 }
895 if (!m_clidsvc->getIDOfTypeInfoName(ti_typename, id)
896 .isSuccess()) {
897 ATH_MSG_DEBUG("** could not find a CLID from type-info ["
898 << System::typeinfoName(*ti) << "]");
899 ATH_MSG_DEBUG("** could not find a CLID from type-info-alias ["
900 << ti_typename << "]");
901 continue;
902 }
903 }
904 } else {
905 // probably a built-in type...
906 if (!m_clidsvc->getIDOfTypeName(::root_typename(type_name), id)
907 .isSuccess()) {
908 ATH_MSG_DEBUG("** could not find a CLID for type-name ["
909 << type_name << "]");
910 continue;
911 }
912 }
913 if (id == 0) {
914 ATH_MSG_DEBUG("** could not find a CLID for type-name ["
915 << type_name << "]");
916 continue;
917 }
918 Athena::RootBranchAddress* addr = new Athena::RootBranchAddress
919 (ROOT_StorageType, id,
920 m_tuple->GetName(),
921 br_name,
922 (unsigned long)(value_ptr),
923 (unsigned long)(m_curEvt-1));
924
925 // recycle old rootaddress, if any.
926 SG::DataProxy* proxy = m_dataStore->proxy (id, sg_key);
927 if (proxy) {
928 proxy->setAddress (addr);
929 }
930 else {
931 auto taddr = new SG::TransientAddress(id, sg_key, addr, false);
932 taddr->setProvider(this, storeID);
933 // only add the *new* TransientAddress to the input list as the *old* ones
934 // are already tracked by the datastore (via the sticky proxies)
935 tads.push_back(taddr);
936 }
937 }
938 }
939 m_needReload = false;
940 // remember that we need to fire a BeginInputFile incident.
941 // we can't fire it just now as some client may need the tree and its
942 // content loaded in the evtstore when their ::handle method is
943 // called.
944 // so we do it later.
945 //MOVED TO handle method - which is fired on BeginEvent after StoreGateSvc
946 //m_fireBIF = true;
947
948 return StatusCode::SUCCESS;
949}
#define ATH_MSG_DEBUG(x)
@ EVENT_STORE
Definition StoreID.h:26

◆ curEvent()

int Athena::RootNtupleEventSelector::curEvent ( const Context & refCtxt) const
overridevirtual

return the current event number.

Returns
The current event number.

Definition at line 722 of file RootNtupleEventSelector.cxx.

723{
724 return m_curEvt;
725}

◆ do_init_io()

StatusCode Athena::RootNtupleEventSelector::do_init_io ( )
private

helper method to init the i/o components

Definition at line 1188 of file RootNtupleEventSelector.cxx.

1189{
1190 // std::cout << "::fetchNtuple..." << std::endl;
1191
1192 // initialize some helper structures and data
1193 {
1195 zero.min_entries = -1;
1196 zero.max_entries = -1;
1197 zero.entries = -1;
1198 m_collEvts.resize (m_tupleNames.size());
1199 for (size_t i = 0; i < m_collEvts.size(); i++) {
1200 m_collEvts[i].resize(m_inputCollectionsName.value().size(), zero);
1201 }
1202 }
1203
1205 m_tupleNames[0]);
1206 if (!m_tuple) {
1207 throw "RootNtupleEventSelector: Unable to fetch Ntuple";
1208 }
1209
1210 // std::cout << "::clear-root-addresses..." << std::endl;
1211 // reset the list of branches
1212 m_needReload = true;
1213
1214 // skip events we are asked to skip
1216 m_nbrEvts = 0;
1217
1218 // std::cout << "::fetchNtuple...[done]" << std::endl;
1219 return StatusCode::SUCCESS;
1220}
std::vector< std::string > m_tupleNames
Names of all trees over which to iterate.
TTree * fetchNtuple(const std::string &fname, const std::string &tupleName) const
helper method to retrieve the correct tuple
void zero(TH2 *h)
zero the contents of a 2d histogram
long min_entries
number of entries up to this collection

◆ endInputFile()

StatusCode Athena::RootNtupleEventSelector::endInputFile ( RootNtupleEventContext * rctx) const
private

Definition at line 426 of file RootNtupleEventSelector.cxx.

427{
428 const FileNames_t& fnames = rctx->files();
429 std::size_t fidx = rctx->fileIndex();
430 m_incsvc->fireIncident(FileIncident(name(), "EndInputFile", fnames[fidx]));
431
432 // prepare for next file, if any...
433 // std::cout << "=========================================================="
434 // << std::endl;
435 // std::cerr << "::switch to next file...\n";
436
437 // iterate over proxies and
438 // mark as garbage and drop the RootBranchAddress (as a side effect of
439 // ::setAddress(NULL).
440 // this way, the next time we hit ::createRootBranchAddress or ::updateAddress
441 // all internal states are kosher.
442 for (const SG::DataProxy* cdp : m_dataStore->proxies()) {
443 if (dynamic_cast<Athena::RootBranchAddress*> (cdp->address()) != nullptr) {
444 if (SG::DataProxy* dp = m_dataStore->proxy_exact (cdp->sgkey())) {
445 dp->setAddress (nullptr);
446 }
447 }
448 }
449
450 const bool forceRemove = false;
451 CHECK( m_dataStore->clearStore(forceRemove) ); //must clear the storegate so that any tampering user did in EndInputFile incident is cleared
452 m_needReload = true;m_fireBIF=true;
453
454 return StatusCode::SUCCESS;
455}
#define CHECK(...)
Evaluate an expression and check for errors.
RootNtupleEventContext::FileNames_t FileNames_t

◆ fetchNtuple()

TTree * Athena::RootNtupleEventSelector::fetchNtuple ( const std::string & fname,
const std::string & tupleName ) const
private

helper method to retrieve the correct tuple

Definition at line 1068 of file RootNtupleEventSelector.cxx.

1070{
1071 // std::cout << "::fetchNtuple(" << fname << ")..." << std::endl;
1072 TTree* tree = NULL;
1073 RootGlobalsRestore rgr;
1074 // std::cout << "::TFile::Open()..." << std::endl;
1075 TFile *f = (TFile*)gROOT->GetListOfFiles()->FindObject(fname.c_str());
1076 TFile* fnew = nullptr;
1077 if (!f) {
1078 f = TFile::Open(fname.c_str(), "READ");
1079 fnew = f;
1080 if (f) {
1081 f->SetName(fname.c_str());
1082 }
1083 }
1084 if (!f || f->IsZombie()) {
1085 ATH_MSG_ERROR("could not open next file in input collection ["
1086 << fname << "]");
1087 if (f) {
1088 f->Close();
1089 }
1090 return tree;
1091 }
1092 // std::cout << "::TFile::GetTree(" << m_tupleName << ")..." << std::endl;
1093 tree = (TTree*)f->Get(tupleName.c_str());
1094 if (!tree) {
1095 ATH_MSG_ERROR("could not retrieve tree [" << tupleName << "]"
1096 << " from file [" << fname << "]");
1097 f->Close();
1098 return tree;
1099 }
1100
1101 if (fnew)
1102 m_files.push_back(fnew);
1103
1104 // std::cout << "::TTree::SetBranchStatus()..." << std::endl;
1105 // disable all branches
1106 tree->SetBranchStatus("*", 0);
1107
1108 if (!m_imetaStore->clearStore().isSuccess()) {
1109 ATH_MSG_INFO("could not clear store [" << m_imetaStore.typeAndName() << "]");
1110 return tree;
1111 }
1112
1113 addMetadataFromDirectoryName(tupleName+"Meta", f);
1114 addMetadataFromDirectoryName("Lumi", f, "Lumi");
1115 return tree;
1116}
void addMetadataFromDirectoryName(const std::string &metadirname, TFile *fileObj, const std::string &prefix="") const

◆ finalize()

StatusCode Athena::RootNtupleEventSelector::finalize ( )
overridevirtual

Definition at line 405 of file RootNtupleEventSelector.cxx.

406{
407 ATH_MSG_INFO ("Finalize...");
408 // FIXME: this should be tweaked/updated if/when a selection function
409 // or filtering predicate is applied (one day?)
410 ATH_MSG_INFO ("Total events read: " << (m_nbrEvts - m_skipEvts));
411
412 // Explicitly delete all the files we created.
413 // If we leave it up to root, then xrootd can get cleaned up before
414 // the root destructors run, leading to a crash.
415 for (TFile* f : m_files)
416 delete f;
417 m_files.clear();
418
419 return StatusCode::SUCCESS;
420}

◆ find_coll_idx()

void Athena::RootNtupleEventSelector::find_coll_idx ( int evtidx,
long & coll_idx,
long & tuple_idx ) const
private

helper method to get the collection index (into m_inputCollectionsName) and tuple index (into ‘m_tupleNames’) / for a given event index evtidx.

helper method to get the collection index (into m_inputCollectionsName) and tuple index (into ‘m_tupleNames’)

returns -1 if not found.

for a given event index evtidx. returns -1 if not found.

Definition at line 1227 of file RootNtupleEventSelector.cxx.

1230{
1231 coll_idx = -1;
1232 tuple_idx = -1;
1233
1234 // std::cout << "--find_coll_idx(" << evtidx << ")..." << std::endl
1235 // << "--collsize: " << m_collEvts.size() << std::endl;
1236 for (size_t ituple = 0; ituple < m_collEvts.size(); ++ituple) {
1237 for (size_t icoll = 0; icoll < m_collEvts[ituple].size(); ++icoll) {
1238 CollMetaData &itr = m_collEvts[ituple][icoll];
1239 if (itr.min_entries == -1) {
1240 TTree *tree = fetchNtuple(m_inputCollectionsName.value()[icoll],
1241 m_tupleNames[ituple]);
1242 if (tree) {
1243 long offset = 0;
1244 if (icoll > 0) {
1245 offset = m_collEvts[ituple][icoll-1].max_entries;
1246 }
1247 else if (ituple > 0) {
1248 offset = m_collEvts[ituple-1].back().max_entries;
1249 }
1250 itr.entries = tree->GetEntriesFast();
1251 itr.min_entries = offset;
1252 itr.max_entries = offset + itr.entries;
1253 } else {
1254 throw "RootNtupleEventSelector: Unable to fetch ntuple";
1255 }
1256 }
1257 // std::cout << "--[" << i << "] => [" << itr.min_entries << ", "
1258 // << itr.max_entries << ") evtidx=[" << evtidx << "]"
1259 // << std::endl;
1260 if (itr.min_entries <= evtidx && evtidx < itr.max_entries) {
1261 coll_idx = icoll;
1262 tuple_idx = ituple;
1263 return;
1264 }
1265 }
1266 }
1267}

◆ handle()

void Athena::RootNtupleEventSelector::handle ( const Incident & incident)
overridevirtual

Definition at line 1278 of file RootNtupleEventSelector.cxx.

1278 {
1279 if(m_fireBIF && incident.type() == IncidentType::BeginEvent) {
1280 //fire the BeginInputFile
1281 m_incsvc->fireIncident(FileIncident(name(), "BeginInputFile", m_tuple->GetCurrentFile()->GetName()));
1282 m_fireBIF=false;
1283 }
1284}

◆ initialize()

StatusCode Athena::RootNtupleEventSelector::initialize ( )
overridevirtual

Definition at line 275 of file RootNtupleEventSelector.cxx.

276{
277 ATH_MSG_INFO ("Enter RootNtupleEventSelector initialization...");
278
279 // retrieve clidsvc
280 if ( !m_clidsvc.retrieve().isSuccess() ) {
282 ("Could not retrieve [" << m_clidsvc.typeAndName() << "]");
283 return StatusCode::FAILURE;
284 }
285
286 // retrieve dictsvc
287 if ( !m_dictsvc.retrieve().isSuccess() ) {
289 ("Could not retrieve [" << m_dictsvc.typeAndName() << "]");
290 return StatusCode::FAILURE;
291 }
292
293 typedef boost::tokenizer<boost::char_separator<char> > tokenizer;
294 boost::char_separator<char> sep (" ;");
295 tokenizer tokens (m_tupleName.value(), sep);
296 m_tupleNames.assign (tokens.begin(), tokens.end());
297
298 if ( m_tupleNames.empty() ) {
300 ("You have to give a TTree name to read from the ROOT files !");
301 return StatusCode::FAILURE;
302 }
303
304 CHECK( m_incsvc.retrieve() );
305 m_incsvc->addListener(this,IncidentType::BeginEvent,99); //used to trigger BeginInputFile on start of first event of file - 99 priority so AFTER storegatesvc done
306
307
309 const std::size_t nbrInputFiles = m_inputCollectionsName.value().size();
310 if ( nbrInputFiles < 1 ) {
312 ("You need to give at least 1 input file !!" << endmsg
313 << "(Got [" << nbrInputFiles << "] file instead !)");
314 return StatusCode::FAILURE;
315 } else {
317 ("Selector configured to read [" << nbrInputFiles << "] file(s)..."
318 << endmsg
319 << " TTree [" << m_tupleName.value() << "]");
320 }
321
322 {
323 // register this service for 'I/O' events
324 ServiceHandle<IIoComponentMgr> iomgr("IoComponentMgr", name());
325 if (!iomgr.retrieve().isSuccess()) {
326 ATH_MSG_FATAL("Could not retrieve IoComponentMgr !");
327 return StatusCode::FAILURE;
328 }
329 if (!iomgr->io_register(this).isSuccess()) {
330 ATH_MSG_FATAL("Could not register myself with the IoComponentMgr !");
331 return StatusCode::FAILURE;
332 }
333 // register input file's names with the I/O manager
334 const std::vector<std::string>& incol = m_inputCollectionsName.value();
335 bool allGood = true;
336 for (std::size_t icol = 0, imax = incol.size(); icol < imax; icol++) {
337 if (!iomgr->io_register(this,
338 IIoComponentMgr::IoMode::READ,
339 incol[icol]).isSuccess()) {
340 ATH_MSG_FATAL("could not register [" << incol[icol] << "] for output !");
341 allGood = false;
342 } else {
343 ATH_MSG_VERBOSE("io_register[" << this->name() << "](" << incol[icol] << ") [ok]");
344 }
345 }
346 if (!allGood) {
347 return StatusCode::FAILURE;
348 }
349 }
350
351 if (!do_init_io().isSuccess()) {
352 return StatusCode::FAILURE;
353 }
354
355 // retrieve event store
356 // this needs to happen *after* having initialized the i/o
357 // as our branches (which need a valid m_ntuple pointer)
358 // may be asked to be registered as we are a ProxyProvider.
359 // retrieving the event store will poke the ProxyProviderSvc...
360 /*
361 if ( !m_dataStore.retrieve().isSuccess() ) {
362 ATH_MSG_ERROR
363 ("Could not retrieve [" << m_dataStore.typeAndName() << "] !!");
364 return StatusCode::FAILURE;
365 }
366
367 // ditto for (input) meta data store
368 if (!m_imetaStore.retrieve().isSuccess()) {
369 ATH_MSG_ERROR
370 ("Could not retrieve [" << m_imetaStore.typeAndName() << "] !!");
371 return StatusCode::FAILURE;
372 }
373
374 // ditto for (output) meta data store
375 if (!m_ometaStore.retrieve().isSuccess()) {
376 ATH_MSG_ERROR
377 ("Could not retrieve [" << m_ometaStore.typeAndName() << "] !!");
378 return StatusCode::FAILURE;
379 }
380 */
381
382 //ensure the Athena::NtupleCnvSvc is in the EventPersistencySvc
383 ServiceHandle<IProperty> epSvc("EventPersistencySvc",name());
384 std::vector<std::string> propVal;
385 CHECK( Gaudi::Parsers::parse( propVal , epSvc->getProperty("CnvServices").toString() ) );
386 bool foundSvc(false);
387 for(const std::string& s : propVal) {
388 if(s=="Athena::xAODCnvSvc") { foundSvc=true; break; }
389 }
390 if(!foundSvc) {
391 propVal.push_back("Athena::NtupleCnvSvc");
392 CHECK( epSvc->setProperty("CnvServices", Gaudi::Utils::toString( propVal ) ));
393 }
394
395 //we should also add ourself as a proxy provider
396 ServiceHandle<IProxyProviderSvc> ppSvc("ProxyProviderSvc",name());
397 CHECK( ppSvc.retrieve() );
398 ppSvc->addProvider( this );
399
400
401
402 return StatusCode::SUCCESS;
403}
#define endmsg
#define ATH_MSG_FATAL(x)
#define ATH_MSG_VERBOSE(x)
int imax(int i, int j)
StatusCode do_init_io()
helper method to init the i/o components
StatusCode parse(std::tuple< Tup... > &tup, const Gaudi::Parsers::InputData &input)
bool allGood
Loop over the SDOs & Digits.

◆ io_reinit()

StatusCode Athena::RootNtupleEventSelector::io_reinit ( )
overridevirtual

Callback method to reinitialize the internal state of the component for I/O purposes (e.g.

Callback method to reinitialize the internal state of the component for I/O purposes (e.g. upon fork(2))

upon fork(2))

Definition at line 730 of file RootNtupleEventSelector.cxx.

731{
732 ATH_MSG_INFO("I/O reinitialization...");
733
734 ServiceHandle<IIoComponentMgr> iomgr("IoComponentMgr", name());
735 if (!iomgr.retrieve().isSuccess()) {
736 ATH_MSG_FATAL("Could not retrieve IoComponentMgr !");
737 return StatusCode::FAILURE;
738 }
739 if (!iomgr->io_hasitem(this)) {
740 ATH_MSG_FATAL("IoComponentMgr does not know about myself !");
741 return StatusCode::FAILURE;
742 }
743 std::vector<std::string> inputCollections = m_inputCollectionsName.value();
744
745 for (std::size_t
746 i = 0,
747 imax = m_inputCollectionsName.value().size();
748 i < imax;
749 ++i) {
750 std::string &fname = inputCollections[i];
751 // std::cout << "--retrieve new name for [" << fname << "]...\n";
752 if (!iomgr->io_contains(this, fname)) {
753 ATH_MSG_ERROR("IoComponentMgr does not know about [" << fname << "] !");
754 return StatusCode::FAILURE;
755 }
756 if (!iomgr->io_retrieve(this, fname).isSuccess()) {
757 ATH_MSG_FATAL("Could not retrieve new value for [" << fname << "] !");
758 return StatusCode::FAILURE;
759 }
760 // std::cout << "--> [" << fname << "]\n" << std::flush;
761 }
762 // all good... copy over.
764
765 // remove our EventInfo if any...
766 // {
767 // const bool force_remove = true;
768 // if (!m_dataStore->clearStore(force_remove).isSuccess()) {
769 // ATH_MSG_ERROR("could not clear event store!");
770 // return StatusCode::FAILURE;
771 // } else {
772 // ATH_MSG_INFO("sgdump: \n" << m_dataStore->dump());
773 // }
774 // }
775
776 // std::cout << "--> do_init_io...\n" << std::flush;
777 if (!do_init_io().isSuccess()) {
778 return StatusCode::FAILURE;
779 }
780
781 ATH_MSG_INFO("I/O reinitialization... [done]");
782 return StatusCode::SUCCESS;
783}

◆ last()

StatusCode Athena::RootNtupleEventSelector::last ( Context & refContext) const
overridevirtual

Definition at line 617 of file RootNtupleEventSelector.cxx.

618{
619 ATH_MSG_ERROR ("............. Last Event Not Implemented .............");
620 return StatusCode::FAILURE;
621}

◆ loadAddresses()

StatusCode Athena::RootNtupleEventSelector::loadAddresses ( StoreID::type storeID,
tadList & list )
overridevirtual

get all new addresses from Provider for this Event.

Definition at line 801 of file RootNtupleEventSelector.cxx.

802{
803 if (m_needReload) {
804 return createRootBranchAddresses(storeID, tads);
805 }
806
807 return StatusCode::SUCCESS;
808}
StatusCode createRootBranchAddresses(StoreID::type storeID, tadList &tads)
helper method to create proxies

◆ next() [1/2]

virtual StatusCode Athena::RootNtupleEventSelector::next ( Context & refCtxt) const
overridevirtual

◆ next() [2/2]

StatusCode Athena::RootNtupleEventSelector::next ( Context & refCtxt,
int jump ) const
overridevirtual

Definition at line 594 of file RootNtupleEventSelector.cxx.

595{
596 ATH_MSG_DEBUG ("next(" << jump << ") : iEvt " << m_curEvt);
597
598 if (self()->seek(ctx, m_curEvt + jump).isSuccess()) {
599 return StatusCode::FAILURE;
600 }
601 return next(ctx);
602}
RootNtupleEventSelector * self() const
non-const access to self (b/c next() is const)
virtual StatusCode seek(Context &refCtxt, int evtnum) const override
Seek to a given event number.
virtual StatusCode next(Context &refCtxt) const override

◆ preLoadAddresses()

StatusCode Athena::RootNtupleEventSelector::preLoadAddresses ( StoreID::type storeID,
tadList & list )
overridevirtual

IAddressProvider interface get all addresses from Provider : Called before Begin Event

IAddressProvider interface get all addresses from Provider : Called before Begin Event

Definition at line 790 of file RootNtupleEventSelector.cxx.

792{
793 // std::cerr << "TTES::preLoadAddresses(" << int(storeID)
794 // << "," << tads.size()
795 // << ")...\n";
796 return StatusCode::SUCCESS;
797}

◆ previous() [1/2]

virtual StatusCode Athena::RootNtupleEventSelector::previous ( Context & refCtxt) const
overridevirtual

◆ previous() [2/2]

StatusCode Athena::RootNtupleEventSelector::previous ( Context & refCtxt,
int jump ) const
overridevirtual

Definition at line 611 of file RootNtupleEventSelector.cxx.

612{
613 return next( ctx, -jump );
614}

◆ releaseContext()

StatusCode Athena::RootNtupleEventSelector::releaseContext ( Context *& refCtxt) const
overridevirtual

Definition at line 647 of file RootNtupleEventSelector.cxx.

648{
649 RootNtupleEventContext *ctx = dynamic_cast<RootNtupleEventContext*>(refCtxt);
650 if ( ctx ) {
651 delete ctx; ctx = 0;
652 return StatusCode::SUCCESS;
653 }
654
655 return StatusCode::FAILURE;
656}

◆ resetCriteria()

StatusCode Athena::RootNtupleEventSelector::resetCriteria ( const std::string & cr,
Context & ctx ) const
overridevirtual

Definition at line 659 of file RootNtupleEventSelector.cxx.

660{
661 ATH_MSG_ERROR ("............. resetCriteria Not Implemented .............");
662 return StatusCode::FAILURE;
663}

◆ rewind()

StatusCode Athena::RootNtupleEventSelector::rewind ( Context & refCtxt) const
overridevirtual

Definition at line 625 of file RootNtupleEventSelector.cxx.

626{
627 return self()->seek(ctxt, 0);
628}

◆ seek()

StatusCode Athena::RootNtupleEventSelector::seek ( Context & ctx,
int evtnum ) const
overridevirtual

Seek to a given event number.

IEvtSelectorSeek interface

Parameters
evtnumThe event number to which to seek.
evtnumThe event number to which to seek.

Definition at line 674 of file RootNtupleEventSelector.cxx.

675{
676 RootNtupleEventContext* rctx = dynamic_cast<RootNtupleEventContext*>(&ctx);
677 if (!rctx) {
678 return StatusCode::FAILURE;
679 }
680
681 // std::cout << "::seek - evtnum=" << evtnum
682 // << " curevt=" << m_curEvt
683 // << " curcol=" << rctx->fileIndex()
684 // << std::endl;
685 long coll_idx, tuple_idx;
686 find_coll_idx(evtnum, coll_idx, tuple_idx);
687 // std::cout << "::seek - evtnum=" << evtnum
688 // << " curevt=" << m_curEvt
689 // << " curcol=" << rctx->fileIndex()
690 // << " colidx=" << coll_idx
691 // << std::endl;
692 if ((coll_idx == -1 || tuple_idx == -1) && evtnum < m_curEvt) {
693 coll_idx = rctx->fileIndex();
694 tuple_idx = rctx->tupleIndex();
695 }
696
697 if (coll_idx == -1 || tuple_idx == -1) {
698 ATH_MSG_INFO("seek: reached end of input.");
699 return StatusCode::RECOVERABLE;
700 }
701
702 if (coll_idx != static_cast<int>(rctx->fileIndex()) ||
703 tuple_idx != static_cast<int>(rctx->tupleIndex()))
704 {
705 // tell everyone we switched files...
706 m_tuple = NULL;
707 CHECK( endInputFile (rctx) );
708 }
709
710 rctx->setFileIndex (coll_idx);
711 rctx->setTupleIndex (tuple_idx);
712 m_curEvt = evtnum;
713
714 return StatusCode::SUCCESS;
715}
void find_coll_idx(int evtidx, long &coll_idx, long &tuple_idx) const
helper method to get the collection index (into m_inputCollectionsName) and tuple index (into ‘m_tupl...
StatusCode endInputFile(RootNtupleEventContext *rctx) const

◆ self()

RootNtupleEventSelector * Athena::RootNtupleEventSelector::self ( ) const
inlineprivate

non-const access to self (b/c next() is const)

Definition at line 177 of file RootNtupleEventSelector.h.

178 { return const_cast<RootNtupleEventSelector*>(this); }
RootNtupleEventSelector(const std::string &name, ISvcLocator *svcLoc)
Constructor with parameters:

◆ setupInputCollection()

void Athena::RootNtupleEventSelector::setupInputCollection ( Gaudi::Details::PropertyBase & inputCollectionsName)
private

callback to synchronize the list of input files

Definition at line 832 of file RootNtupleEventSelector.cxx.

833{
834 // nothing ?
835 return;
836}

◆ size()

int Athena::RootNtupleEventSelector::size ( Context & refCtxt) const
overridevirtual

ICollectionSize interface

return total number of events in all TTree

Definition at line 1270 of file RootNtupleEventSelector.cxx.

1270 {
1271 //use find_coll_idx to trigger a population of the m_collEvts
1272 long coll_idx, tuple_idx;
1273 find_coll_idx(-1, coll_idx, tuple_idx);
1274 return m_collEvts.back().back().max_entries;
1275}

◆ updateAddress()

StatusCode Athena::RootNtupleEventSelector::updateAddress ( StoreID::type storeID,
SG::TransientAddress * tad,
const EventContext & ctx )
overridevirtual

update a transient Address

Definition at line 812 of file RootNtupleEventSelector.cxx.

814{
815 if (tad) {
816 if (m_dataStore->proxy_exact (tad->sgkey())) {
817 return StatusCode::SUCCESS;
818 }
819 return StatusCode::FAILURE;
820 }
821 // do nothing.
822 return StatusCode::SUCCESS;
823}
sgkey_t sgkey() const
Set the primary (hashed) SG key.

◆ Athena::RootNtupleEventContext

friend class Athena::RootNtupleEventContext
friend

Definition at line 50 of file RootNtupleEventSelector.h.

Member Data Documentation

◆ m_activeBranchNames

StringArrayProperty Athena::RootNtupleEventSelector::m_activeBranchNames
private

List of branches to activate in the TTree.

Definition at line 214 of file RootNtupleEventSelector.h.

◆ m_clidsvc

ICLIDSvc_t Athena::RootNtupleEventSelector::m_clidsvc
private

Pointer to the IClassIDSvc.

Definition at line 197 of file RootNtupleEventSelector.h.

◆ m_collEvts

std::vector<std::vector<CollMetaData> > Athena::RootNtupleEventSelector::m_collEvts
mutableprivate

cache of the number of entries for each collection Indexed like [tuple][collection]

Definition at line 238 of file RootNtupleEventSelector.h.

◆ m_curEvt

long Athena::RootNtupleEventSelector::m_curEvt
mutableprivate

current event index

Definition at line 226 of file RootNtupleEventSelector.h.

◆ m_dataStore

StoreGateSvc_t Athena::RootNtupleEventSelector::m_dataStore
private

Pointer to the StoreGateSvc event store.

Definition at line 187 of file RootNtupleEventSelector.h.

◆ m_dictsvc

IDictSvc_t Athena::RootNtupleEventSelector::m_dictsvc
private

Pointer to the IDictLoaderSvc.

Definition at line 201 of file RootNtupleEventSelector.h.

◆ m_files

std::vector<TFile*> Athena::RootNtupleEventSelector::m_files
mutableprivate

Definition at line 265 of file RootNtupleEventSelector.h.

◆ m_fireBIF

bool Athena::RootNtupleEventSelector::m_fireBIF
mutableprivate

Definition at line 256 of file RootNtupleEventSelector.h.

◆ m_imetaStore

StoreGateSvc_t Athena::RootNtupleEventSelector::m_imetaStore
private

Pointer to the StoreGateSvc input metadata store.

Definition at line 190 of file RootNtupleEventSelector.h.

◆ m_incsvc

IIncSvc_t Athena::RootNtupleEventSelector::m_incsvc
private

Handle to the incident service.

Definition at line 205 of file RootNtupleEventSelector.h.

◆ m_inputCollectionsName

StringArrayProperty Athena::RootNtupleEventSelector::m_inputCollectionsName
private

List of input files containing TTree.

Definition at line 208 of file RootNtupleEventSelector.h.

◆ m_nbrEvts

long Athena::RootNtupleEventSelector::m_nbrEvts
mutableprivate

Number of Events read so far.

Definition at line 223 of file RootNtupleEventSelector.h.

◆ m_needReload

bool Athena::RootNtupleEventSelector::m_needReload
mutableprivate

The (python) selection function to apply on the TChain we are reading.

Definition at line 248 of file RootNtupleEventSelector.h.

◆ m_ometaStore

StoreGateSvc_t Athena::RootNtupleEventSelector::m_ometaStore
private

Pointer to the StoreGateSvc output metadata store.

Definition at line 193 of file RootNtupleEventSelector.h.

◆ m_skipEvts

long Athena::RootNtupleEventSelector::m_skipEvts
private

Number of events to skip at the beginning.

Definition at line 217 of file RootNtupleEventSelector.h.

◆ m_tuple

TTree* Athena::RootNtupleEventSelector::m_tuple
mutableprivate

current tree being read

Definition at line 241 of file RootNtupleEventSelector.h.

◆ m_tupleName

StringProperty Athena::RootNtupleEventSelector::m_tupleName
private

Name of TTree to load from collection of input files.

Definition at line 211 of file RootNtupleEventSelector.h.

◆ m_tupleNames

std::vector<std::string> Athena::RootNtupleEventSelector::m_tupleNames
private

Names of all trees over which to iterate.

Definition at line 220 of file RootNtupleEventSelector.h.


The documentation for this class was generated from the following files: