Skip to content
Snippets Groups Projects
Commit 67424151 authored by Nils Erik Krumnack's avatar Nils Erik Krumnack Committed by Atlas Nightlybuild
Browse files

Merge branch 'ImproveEventSelector-21.2' into '21.2'

only load branches actually found in the input collection. Previously we were…

See merge request atlas/athena!8380

(cherry picked from commit 5259dcccd2e9b4fe0685e02d911d3c3f194f8b48)

b8cd5899 only load branches actually found in the input collection. Previously we were…
parent 2bbff906
No related merge requests found
......@@ -717,17 +717,22 @@ xAODEventSelector::createRootBranchAddresses(StoreID::type storeID,
return StatusCode::FAILURE;
}
TTree* inputTree = dynamic_cast<TTree*>(m_tfile->Get(m_tupleName.value().c_str()));
if(inputTree!=0) {
ATH_MSG_DEBUG("Reading xAOD::EventFormat");
ATH_MSG_DEBUG("Reading xAOD::EventFormat");
// m_tevent->dump();
// m_tevent->dump();
const void* value_ptr = m_tevent; //passed as 'parameter' to the address object
const void* value_ptr = m_tevent; //passed as 'parameter' to the address object
std::set<std::string> missingAux;
std::set<std::string> missingAux;
for( auto itr = m_tevent->inputEventFormat()->begin(); itr!=m_tevent->inputEventFormat()->end();++itr) {
//ATH_MSG_DEBUG("EFE:" << itr->first << " branchName = " << itr->second.branchName() << " className=" << itr->second.className());
for( auto itr = m_tevent->inputEventFormat()->begin(); itr!=m_tevent->inputEventFormat()->end();++itr) {
if(inputTree->GetBranch(itr->second.branchName().c_str())==0) continue; //skip branches that are not available in the input collection
ATH_MSG_VERBOSE("EFE:" << itr->first << " branchName = " << itr->second.branchName() << " className=" << itr->second.className());
CLID id = 0;
if( m_clidsvc->getIDOfTypeInfoName(itr->second.className(), id).isFailure() &&
m_clidsvc->getIDOfTypeName(itr->second.className(), id).isFailure()) {
......@@ -796,13 +801,17 @@ xAODEventSelector::createRootBranchAddresses(StoreID::type storeID,
m_rootAddresses.insert(std::make_pair(taddr, true));
}
// }
}
}
if(missingAux.size()) {
std::string allAux; for(auto& s : missingAux) allAux += s + ", ";
ATH_MSG_WARNING("The following AuxStore types are not directly accessible (missing CLID, possibly from schema evolution): " << allAux);
if(missingAux.size()) {
std::string allAux; for(auto& s : missingAux) allAux += s + ", ";
ATH_MSG_WARNING("The following AuxStore types are not directly accessible (missing CLID, possibly from schema evolution): " << allAux);
}
} //end if block of requiring input tree to exist
else {
ATH_MSG_DEBUG("No input collection " << m_tupleName.value() << " found in input file " << m_tfile->GetTitle() );
}
m_needReload = false;
// remember that we need to fire a BeginInputFile incident.
......
File mode changed from 100755 to 100644
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment