25 #include "boost/program_options.hpp"
35 typedef std::map<std::string, std::vector<edm::BranchDescription> >
IdToBranches;
46 typedef std::map<edm::ParameterSetID, edm::ParameterSetBlob>
ParameterSetMap;
57 simpleId_(iSimpleId) {
60 void addChild(HistoryNode
const&
child) {
61 children_.push_back(child);
65 parameterSetID()
const {
66 return config_.parameterSetID();
71 return config_.processName();
76 return children_.size();
81 return &children_.back();
84 typedef std::vector<HistoryNode>::const_iterator const_iterator;
85 typedef std::vector<HistoryNode>::iterator iterator;
87 iterator
begin() {
return children_.begin();}
88 iterator
end() {
return children_.end();}
90 const_iterator
begin()
const {
return children_.begin();}
91 const_iterator
end()
const {
return children_.end();}
93 void print(std::ostream& os)
const {
94 os << config_.processName()
95 <<
" '" << config_.passID() <<
"' '"
96 << config_.releaseVersion() <<
"' ["
98 << config_.parameterSetID() <<
")"
103 void printEventSetupHistory(ParameterSetMap
const& iPSM,
104 std::vector<std::string>
const& iFindMatch,
105 std::ostream& oErrorLog)
const;
106 void printOtherModulesHistory(ParameterSetMap
const& iPSM,
108 std::vector<std::string>
const& iFindMatch,
109 std::ostream& oErrorLog)
const;
110 void printTopLevelPSetsHistory(ParameterSetMap
const& iPSM,
111 std::vector<std::string>
const& iFindMatch,
112 std::ostream& oErrorLog)
const;
115 configurationID()
const {
122 std::vector<HistoryNode> children_;
123 unsigned int simpleId_;
126 std::ostream&
operator<<(std::ostream& os, HistoryNode
const&
node) {
130 bool HistoryNode::sort_ =
false;
137 for(
auto const&
process : iHist) {
139 <<
process.processName() <<
" '"
141 <<
process.releaseVersion() <<
"' ("
142 <<
process.parameterSetID() <<
")"
144 indent += indentDelta;
149 void HistoryNode::printHistory(
std::string const& iIndent)
const {
152 for(
auto const& item : *
this) {
154 item.printHistory(indent + indentDelta);
162 std::ostringstream
result;
165 if(0 == name.size()) {
169 result << iType <<
": " << name <<
" " << iProcessName <<
"\n"
175 void HistoryNode::printEventSetupHistory(ParameterSetMap
const& iPSM,
176 std::vector<std::string>
const& iFindMatch,
177 std::ostream& oErrorLog)
const {
178 for(
auto const& itH : *
this) {
180 ParameterSetMap::const_iterator itFind = iPSM.find(itH.parameterSetID());
181 if(itFind == iPSM.end()){
182 oErrorLog <<
"No ParameterSetID for " << itH.parameterSetID() << std::endl;
185 std::vector<std::string> sourceStrings, moduleStrings;
187 std::vector<std::string> sources = processConfig.
getParameter<std::vector<std::string> >(
"@all_essources");
188 for(
auto& itM : sources) {
193 bool foundMatch =
true;
194 if(!iFindMatch.empty()) {
195 for (
auto const& stringToFind : iFindMatch) {
196 if (retValue.find(stringToFind) == std::string::npos) {
203 sourceStrings.push_back(
std::move(retValue));
207 std::vector<std::string>
modules = processConfig.getParameter<std::vector<std::string> >(
"@all_esmodules");
208 for(
auto& itM : modules) {
213 bool foundMatch =
true;
214 if(!iFindMatch.empty()) {
215 for (
auto const& stringToFind : iFindMatch) {
216 if (retValue.find(stringToFind) == std::string::npos) {
223 moduleStrings.push_back(
std::move(retValue));
227 std::sort(sourceStrings.begin(), sourceStrings.end());
228 std::sort(moduleStrings.begin(), moduleStrings.end());
230 std::copy(sourceStrings.begin(), sourceStrings.end(),
231 std::ostream_iterator<std::string>(
std::cout,
"\n"));
232 std::copy(moduleStrings.begin(), moduleStrings.end(),
233 std::ostream_iterator<std::string>(
std::cout,
"\n"));
236 itH.printEventSetupHistory(iPSM, iFindMatch, oErrorLog);
243 std::ostringstream
result;
247 result <<
"Module: " << label <<
" " << iProcessName <<
"\n" <<
" parameters: ";
252 void HistoryNode::printOtherModulesHistory(ParameterSetMap
const& iPSM,
254 std::vector<std::string>
const& iFindMatch,
255 std::ostream& oErrorLog)
const {
256 for(
auto const& itH : *
this) {
258 ParameterSetMap::const_iterator itFind = iPSM.find(itH.parameterSetID());
259 if(itFind == iPSM.end()){
260 oErrorLog <<
"No ParameterSetID for " << itH.parameterSetID() << std::endl;
263 std::vector<std::string> moduleStrings;
265 std::vector<std::string> modules = processConfig.
getParameter<std::vector<std::string> >(
"@all_modules");
266 for(
auto& itM : modules) {
268 if(iModules.end() == iModules.find(std::make_pair(itH.processName(), itM))) {
273 bool foundMatch =
true;
274 if(!iFindMatch.empty()) {
275 for (
auto const& stringToFind : iFindMatch) {
276 if (retValue.find(stringToFind) == std::string::npos) {
283 moduleStrings.push_back(
std::move(retValue));
288 std::sort(moduleStrings.begin(), moduleStrings.end());
290 std::copy(moduleStrings.begin(), moduleStrings.end(),
291 std::ostream_iterator<std::string>(
std::cout,
"\n"));
293 itH.printOtherModulesHistory(iPSM, iModules, iFindMatch, oErrorLog);
297 static void appendToSet(std::set<std::string>&iSet, std::vector<std::string>
const& iFrom){
298 for(
auto const&
n : iFrom) {
306 std::ostringstream
result;
309 result <<
"PSet: " << iName <<
" " << iProcessName <<
"\n" <<
" parameters: ";
315 void HistoryNode::printTopLevelPSetsHistory(ParameterSetMap
const& iPSM,
316 std::vector<std::string>
const& iFindMatch,
317 std::ostream& oErrorLog)
const {
318 for(
auto const& itH : *
this) {
320 ParameterSetMap::const_iterator itFind = iPSM.find(itH.parameterSetID());
321 if(itFind == iPSM.end()){
322 oErrorLog <<
"No ParameterSetID for " << itH.parameterSetID() << std::endl;
326 std::set<std::string> namesToExclude;
327 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_modules"));
328 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_sources"));
329 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_loopers"));
331 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_esmodules"));
332 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_essources"));
333 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_esprefers"));
334 if (processConfig.existsAs<std::vector<std::string>>(
"all_aliases")) {
335 appendToSet(namesToExclude,processConfig.getParameter<std::vector<std::string> >(
"@all_aliases"));
338 std::vector<std::string> allNames{};
339 processConfig.getParameterSetNames(allNames);
341 std::vector<std::string>
results;
342 for(
auto const&
name: allNames){
343 if (
name.size() == 0 ||
'@' ==
name[0] || namesToExclude.find(
name)!=namesToExclude.end()) {
348 bool foundMatch =
true;
349 if(!iFindMatch.empty()) {
350 for (
auto const& stringToFind : iFindMatch) {
351 if (retValue.find(stringToFind) == std::string::npos) {
362 std::sort(results.begin(), results.end());
364 std::copy(results.begin(), results.end(),
365 std::ostream_iterator<std::string>(
std::cout,
"\n"));
367 itH.printTopLevelPSetsHistory(iPSM, iFindMatch, oErrorLog);
373 std::unique_ptr<TFile>
377 auto slc = std::make_shared<edm::serviceregistry::ServiceWrapper<edm::SiteLocalConfig> >(slcptr);
382 fileNames.push_back(filename);
386 <<
"File " << filename <<
" was not found or could not be opened.\n";
389 std::unique_ptr<TFile>
result(TFile::Open(
catalog.fileNames()[0].c_str()));
392 <<
"File " << fileNames[0] <<
" was not found or could not be opened.\n";
401 std::unique_ptr<TFile>
403 gErrorIgnoreLevel = kFatal;
404 std::unique_ptr<TFile>
result(TFile::Open(filename.c_str()));
405 gErrorIgnoreLevel =
kError;
408 return makeTFileWithLookup(filename);
416 char const* trackiness = (psetEntry.
isTracked()?
"tracked":
"untracked");
417 os <<
"PSet " << trackiness <<
" = (";
418 prettyPrint(os, psetEntry.
pset(), iIndent + iIndentDelta, iIndentDelta);
424 std::vector<edm::ParameterSet>
const& vps = vpsetEntry.
vpset();
425 os <<
"VPSet " << (vpsetEntry.
isTracked() ?
"tracked" :
"untracked") <<
" = ({" << std::endl;
429 for(
auto const& item : vps) {
430 os << start << newIndent;
437 os << iIndent<<
"})";
445 oStream <<
"{" << std::endl;
446 for(
auto const& item : iPSet.
tbl()) {
448 oStream << newIndent<< item.first <<
": " << item.second << std::endl;
450 for(
auto const& item : iPSet.
psetTable()) {
453 oStream << newIndent << item.first <<
": ";
460 oStream << newIndent << item.first <<
": ";
464 oStream << iIndent<<
"}";
475 bool showDependencies,
476 bool extendedAncestors,
477 bool extendedDescendants,
478 bool excludeESModules,
480 bool showTopLevelPSets,
481 std::vector<std::string>
const& findMatch,
482 bool dontPrintProducts,
496 std::set<edm::BranchID>& ancestorBranchIDs,
497 std::ostringstream& sout,
501 std::ostringstream& sout,
532 bool showDependencies,
533 bool extendedAncestors,
534 bool extendedDescendants,
535 bool excludeESModules,
536 bool showOtherModules,
537 bool showTopLevelPSets,
538 std::vector<std::string>
const& findMatch,
539 bool dontPrintProducts,
542 inputFile_(makeTFile(filename)),
546 showDependencies_(showDependencies),
547 extendedAncestors_(extendedAncestors),
548 extendedDescendants_(extendedDescendants),
549 excludeESModules_(excludeESModules),
550 showOtherModules_(showOtherModules),
551 showTopLevelPSets_(showTopLevelPSets),
552 findMatch_(findMatch),
553 dontPrintProducts_(dontPrintProducts),
554 dumpPSetID_(dumpPSetID) {
576 std::cout <<
"No event filtering information is available.\n";
577 std::cout <<
"------------------------------\n";
579 std::cout <<
"Event filtering information for "
581 <<
" processing steps is available.\n"
582 <<
"The ParameterSets will be printed out, "
583 <<
"with the oldest printed first.\n";
599 if(history->GetEntry(0) <= 0) {
600 std::cout <<
"No event filtering information is available; the event history tree has no entries\n";
608 assert (eventSelectionsBranch != 0);
611 eventSelectionsBranch->SetAddress(&pids);
612 if(eventSelectionsBranch->GetEntry(0) <= 0) {
613 std::cout <<
"No event filtering information is available; the event selections branch has no entries\n";
622 std::cout <<
"ParameterSetID: " <<
id <<
'\n';
624 ParameterSetMap::const_iterator
i =
psm_.find(
id);
625 if(i ==
psm_.end()) {
626 std::cout <<
"We are unable to find the corresponding ParameterSet\n";
629 if(
id == empty.
id()) {
630 std::cout <<
"But it would have been empty anyway\n";
640 std::cout <<
" -------------------------\n";
645 std::cout <<
"Processing History:" << std::endl;
646 if(1 ==
phv_.size()) {
650 std::map<edm::ProcessConfigurationID, unsigned int> simpleIDs;
651 for(
auto const& ph :
phv_) {
654 for(
auto const& pc : ph) {
655 if(parent->size() == 0) {
656 unsigned int id = simpleIDs[pc.id()];
659 simpleIDs[pc.id()] = id;
661 parent->addChild(HistoryNode(pc,
id));
662 parent = parent->lastChildAddress();
665 bool isUnique =
true;
666 for(
auto& child : *parent) {
667 if(child.configurationID() == pc.id()) {
674 simpleIDs[pc.id()] = parent->size() + 1;
675 parent->addChild(HistoryNode(pc, simpleIDs[pc.id()]));
676 parent = parent->lastChildAddress();
694 ParameterSetMap* pPsm = &
psm_;
700 typedef std::pair<edm::ParameterSetID, edm::ParameterSetBlob> IdToBlobs;
702 IdToBlobs* pIdToBlob = &idToBlob;
704 for(
long long i = 0;
i != psetTree->GetEntries(); ++
i) {
705 psetTree->GetEntry(
i);
706 psm_.insert(idToBlob);
733 for(
auto const& item :
psm_) {
735 pset.
setID(item.first);
741 for(
auto const& history :
phv_) {
742 for(
auto const&
process : history) {
751 else if(!phm.empty()) {
752 for(
auto const& history : phm) {
753 phv_.push_back(history.second);
754 for(
auto const&
process : history.second) {
767 throw cms::Exception(
"Command Line Argument") <<
"Illegal ParameterSetID string. It should contain 32 hexadecimal characters";
774 std::map<edm::BranchID, std::set<edm::ParentageID> > perProductParentage;
778 if(
nullptr == parentageTree) {
779 std::cerr <<
"ERROR, no Parentage tree available so can not show dependencies/n";
787 std::vector<edm::ParentageID> orderedParentageIDs;
788 orderedParentageIDs.reserve(parentageTree->GetEntries());
793 parentageTree->GetEntry(
i);
795 orderedParentageIDs.push_back(parentageBuffer.
id());
800 if(0 == eventMetaTree) {
803 if(0 == eventMetaTree) {
811 if(0!=storedProvBranch) {
812 std::vector<edm::StoredProductProvenance>
info;
813 std::vector<edm::StoredProductProvenance>* pInfo = &
info;
814 storedProvBranch->SetAddress(&pInfo);
815 for(Long64_t
i = 0, numEntries = eventMetaTree->GetEntries();
i <
numEntries; ++
i) {
816 storedProvBranch->GetEntry(
i);
817 for(
auto const& item : info) {
819 perProductParentage[bid].insert(orderedParentageIDs[item.parentageIDIndex_]);
825 if (0 != productProvBranch) {
826 std::vector<edm::ProductProvenance>
info;
827 std::vector<edm::ProductProvenance>* pInfo = &
info;
828 productProvBranch->SetAddress(&pInfo);
829 for(Long64_t
i = 0, numEntries = eventMetaTree->GetEntries();
i <
numEntries; ++
i) {
830 productProvBranch->GetEntry(
i);
831 for(
auto const& item : info) {
832 perProductParentage[item.branchID()].insert(item.parentageID());
836 std::cerr <<
" ERROR, could not find provenance information so can not show dependencies\n";
846 std::map<edm::BranchID, std::set<edm::BranchID> > parentToChildren;
850 for (
auto const& itParentageSet : perProductParentage) {
852 for (
auto const& itParentageID : itParentageSet.second) {
855 for(
auto const& branch : parentage->
parents()) {
856 parentToChildren[branch].insert(childBranchID);
859 std::cerr <<
" ERROR:parentage info not in registry ParentageID=" << itParentageID << std::endl;
869 std::cout <<
"---------Producers with data in file---------" << std::endl;
876 std::map<edm::BranchID, std::string> branchIDToBranchName;
878 for(
auto const& processConfig :
phc_) {
880 if(
nullptr == processParameterSet || processParameterSet->
empty()) {
884 auto& product = item.second;
885 if(product.processName() != processConfig.processName()) {
892 branchIDToBranchName[product.branchID()] = product.branchName();
899 if(moduleLabel ==
source) {
912 s << moduleParameterSetCopy.
id();
914 s << moduleParameterSet.
id();
916 moduleToIdBranches[std::make_pair(product.processName(), product.moduleLabel())][s.str()].push_back(product);
921 for(
auto const& item : moduleToIdBranches) {
922 std::ostringstream sout;
923 sout <<
"Module: " << item.first.second <<
" " << item.first.first << std::endl;
924 std::set<edm::BranchID> allBranchIDsForLabelAndProcess;
926 for(
auto const& idBranch : idToBranches) {
927 sout <<
" PSet id:" << idBranch.first << std::endl;
929 sout <<
" products: {" << std::endl;
931 std::set<edm::BranchID> branchIDs;
932 for(
auto const& branch : idBranch.second) {
934 sout <<
" " << branch.branchName() << std::endl;
936 branchIDs.insert(branch.branchID());
937 allBranchIDsForLabelAndProcess.insert(branch.branchID());
939 sout <<
" }" << std::endl;
941 ParameterSetMap::const_iterator itpsm = psm_.find(psid);
942 if(psm_.end() == itpsm) {
944 errorLog_ <<
"No ParameterSetID for " << psid << std::endl;
947 sout <<
" parameters: ";
953 sout <<
" dependencies: {" << std::endl;
954 std::set<edm::ParentageID> parentageIDs;
955 for(
auto const& branch : branchIDs) {
958 std::set<edm::ParentageID>
const&
temp = perProductParentage[branch];
959 parentageIDs.insert(temp.begin(), temp.end());
961 for(
auto const& parentID : parentageIDs) {
963 if(
nullptr != parentage) {
964 for(
auto const& branch : parentage->
parents()) {
965 sout <<
" " << branchIDToBranchName[branch] << std::endl;
968 sout <<
" ERROR:parentage info not in registry ParentageID=" << parentID << std::endl;
971 if(parentageIDs.empty()) {
972 sout <<
" no dependencies recorded (event may not contain data from this module)" << std::endl;
974 sout <<
" }" << std::endl;
978 sout <<
" extendedAncestors: {" << std::endl;
979 std::set<edm::BranchID> ancestorBranchIDs;
980 for (
auto const& branchID : allBranchIDsForLabelAndProcess) {
981 addAncestors(branchID, ancestorBranchIDs, sout, perProductParentage);
983 for (
auto const& ancestorBranchID : ancestorBranchIDs) {
984 sout <<
" " << branchIDToBranchName[ancestorBranchID] <<
"\n";
986 sout <<
" }" << std::endl;
990 sout <<
" extendedDescendants: {" << std::endl;
991 std::set<edm::BranchID> descendantBranchIDs;
992 for (
auto const& branchID : allBranchIDsForLabelAndProcess) {
993 addDescendants(branchID, descendantBranchIDs, sout, parentToChildren);
995 for (
auto const& descendantBranchID : descendantBranchIDs) {
996 sout <<
" " << branchIDToBranchName[descendantBranchID] <<
"\n";
998 sout <<
" }" << std::endl;
1000 bool foundMatch =
true;
1002 for (
auto const& stringToFind :
findMatch_) {
1003 if (sout.str().find(stringToFind) == std::string::npos) {
1014 std::cout <<
"---------Other Modules---------" << std::endl;
1019 std::cout <<
"---------EventSetup---------" << std::endl;
1024 std::cout <<
"---------Top Level PSets---------" << std::endl;
1038 std::set<edm::ParentageID>
const& parentIDs = perProductParentage[branchID];
1039 for (
auto const& parentageID : parentIDs) {
1041 if(0 != parentage) {
1042 for(
auto const& branch : parentage->
parents()) {
1044 if(ancestorBranchIDs.insert(branch).second) {
1045 addAncestors(branch, ancestorBranchIDs, sout, perProductParentage);
1049 sout <<
" ERROR:parentage info not in registry ParentageID=" << parentageID << std::endl;
1058 for (
auto const& childBranchID : parentToChildren[branchID]) {
1059 if (descendantBranchIDs.insert(childBranchID).second) {
1060 addDescendants(childBranchID, descendantBranchIDs, sout, parentToChildren);
1090 using namespace boost::program_options;
1093 descString +=
" [options] <filename>";
1094 descString +=
"\nAllowed options";
1095 options_description desc(descString);
1099 ,
"alphabetially sort EventSetup components")
1101 ,
"print what data each EDProducer is directly dependent upon")
1102 (kExtendedAncestorsCommandOpt
1103 ,
"print what data each EDProducer is dependent upon including indirect dependences")
1105 ,
"print what data depends on the data each EDProducer produces including indirect dependences")
1106 (kExcludeESModulesCommandOpt
1107 ,
"do not print ES module information")
1109 ,
"show all modules (not just those that created data in the file)")
1110 (kShowTopLevelPSetsCommandOpt,
"show all top level PSets")
1112 "show only modules whose information contains the matching string (or all the matching strings, this option can be repeated with different strings)")
1114 ,
"do not print products produced by module")
1115 (kDumpPSetIDCommandOpt, value<std::string>()
1116 ,
"print the parameter set associated with the parameter set ID string (and print nothing else)")
1120 options_description hidden;
1121 hidden.add_options()(
kFileNameOpt, value<std::string>(),
"file name");
1124 options_description cmdline_options;
1125 cmdline_options.add(desc).add(hidden);
1127 positional_options_description
p;
1128 p.add(kFileNameOpt, -1);
1132 store(command_line_parser(argc, argv).
options(cmdline_options).positional(
p).
run(), vm);
1134 }
catch(
error const& iException) {
1139 if(vm.count(kHelpOpt)) {
1144 if(vm.count(kSortOpt)) {
1145 HistoryNode::sort_ =
true;
1148 bool showDependencies =
false;
1149 if(vm.count(kDependenciesOpt)) {
1150 showDependencies =
true;
1153 bool extendedAncestors =
false;
1154 if(vm.count(kExtendedAncestorsOpt)) {
1155 extendedAncestors =
true;
1158 bool extendedDescendants =
false;
1159 if(vm.count(kExtendedDescendantsOpt)) {
1160 extendedDescendants =
true;
1163 bool excludeESModules =
false;
1164 if(vm.count(kExcludeESModulesOpt)) {
1165 excludeESModules =
true;
1168 bool showAllModules =
false;
1169 if(vm.count(kShowAllModulesOpt)) {
1170 showAllModules =
true;
1173 bool showTopLevelPSets =
false;
1174 if(vm.count(kShowTopLevelPSetsOpt)) {
1175 showTopLevelPSets=
true;
1179 if(vm.count(kFileNameOpt)) {
1182 }
catch(boost::bad_any_cast
const&
e) {
1187 std::cout <<
"Data file not specified." << std::endl;
1193 if(vm.count(kDumpPSetIDOpt)) {
1196 }
catch(boost::bad_any_cast
const&
e) {
1202 std::vector<std::string> findMatch;
1203 if(vm.count(kFindMatchOpt)) {
1205 findMatch = vm[
kFindMatchOpt].as<std::vector<std::string> >();
1206 }
catch(boost::bad_any_cast
const&
e) {
1212 bool dontPrintProducts =
false;
1213 if(vm.count(kDontPrintProductsOpt)) {
1214 dontPrintProducts=
true;
1218 gErrorIgnoreLevel =
kError;
1221 excludeESModules, showAllModules, showTopLevelPSets, findMatch, dontPrintProducts, dumpPSetID);
1238 std::cerr <<
"Unknown exception caught\n";
std::stringstream errorLog_
static char const *const kDontPrintProductsCommandOpt
std::vector< ProcessHistory > ProcessHistoryVector
virtual char const * what() const
void setID(ParameterSetID const &id)
T getParameter(std::string const &) const
std::string const & idToParameterSetBlobsBranchName()
std::vector< ProcessConfiguration > ProcessConfigurationVector
std::string const & BranchTypeToMetaDataTreeName(BranchType const &branchType)
tuple start
Check for commandline option errors.
static char const *const kDumpPSetIDOpt
static char const *const kDependenciesOpt
std::string const & parentageTreeName()
bool existsAs(std::string const ¶meterName, bool trackiness=true) const
checks if a parameter exists as a given type
static char const *const kFindMatchCommandOpt
static char const *const kShowTopLevelPSetsCommandOpt
ParameterSetID id() const
std::string print(const Track &, edm::Verbosity=edm::Concise)
Track print utility.
edm::ProductRegistry reg_
void addAncestors(edm::BranchID const &branchID, std::set< edm::BranchID > &ancestorBranchIDs, std::ostringstream &sout, std::map< edm::BranchID, std::set< edm::ParentageID > > &perProductParentage) const
void dumpParameterSetForID_(edm::ParameterSetID const &id)
static char const *const kHelpOpt
HistoryNode historyGraph_
static char const *const kDontPrintProductsOpt
std::string const & eventSelectionsBranchName()
std::ostream & operator<<(std::ostream &out, const ALILine &li)
void dumpEventFilteringParameterSets_(TFile *file)
edm::ProcessHistoryVector phv_
static ServiceToken createContaining(std::auto_ptr< T > iService)
create a service token that holds the service defined by iService
static char const *const kDependenciesCommandOpt
std::vector< EventSelectionID > EventSelectionIDVector
static char const *const kHelpCommandOpt
std::string const & parameterSetsTreeName()
static std::string const input
static char const *const kShowTopLevelPSetsOpt
int main(int argc, char **argv)
std::vector< BranchID > const & parents() const
static char const *const kShowAllModulesCommandOpt
ParameterSet const & pset() const
returns the PSet
static char const *const kExcludeESModulesCommandOpt
std::string const & processHistoryMapBranchName()
static char const *const kSortOpt
bool extendedDescendants_
bool getMapped(key_type const &k, value_type &result) const
EventSelectionIDVector const & eventSelectionIDs() const
static char const *const kExcludeESModulesOpt
std::map< std::pair< std::string, std::string >, IdToBranches > ModuleToIdBranches
void dumpEventFilteringParameterSets(edm::EventSelectionIDVector const &ids)
std::string const & eventHistoryBranchName()
Long64_t numEntries(TFile *hdl, std::string const &trname)
static char const *const kSortCommandOpt
std::string eventSetupComponent(char const *iType, std::string const &iCompName, edm::ParameterSet const &iProcessConfig, std::string const &iProcessName)
std::string nonProducerComponent(std::string const &iCompName, edm::ParameterSet const &iProcessConfig, std::string const &iProcessName)
bool getMapped(key_type const &k, value_type &result) const
std::string const & BranchTypeToBranchEntryInfoBranchName(BranchType const &branchType)
std::vector< ParameterSet > const & vpset() const
returns the VPSet
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
ProvenanceDumper(std::string const &filename, bool showDependencies, bool extendedAncestors, bool extendedDescendants, bool excludeESModules, bool showAllModules, bool showTopLevelPSets, std::vector< std::string > const &findMatch, bool dontPrintProducts, std::string const &dumpPSetID)
ProvenanceDumper & operator=(ProvenanceDumper const &)=delete
std::string const & metaDataTreeName()
std::string const & BranchTypeToProductTreeName(BranchType const &branchType)
std::unique_ptr< TFile > inputFile_
static char const *const kExtendedAncestorsCommandOpt
static std::string const triggerResults
bool isRegistered() const
Hash< ParameterSetType > ParameterSetID
std::string const & parameterSetMapBranchName()
static void appendToSet(std::set< std::string > &iSet, std::vector< std::string > const &iFrom)
static std::ostream & prettyPrint(std::ostream &oStream, edm::ParameterSet const &iPSet, std::string const &iIndent, std::string const &iIndentDelta)
std::string const & processHistoryBranchName()
std::map< std::string, std::vector< edm::BranchDescription > > IdToBranches
void dumpProcessHistory_()
edm::ProcessConfigurationVector phc_
psettable const & psetTable() const
void sort_all(RandomAccessSequence &s)
wrappers for std::sort
ParameterSet const & getParameterSet(std::string const &) const
static char const *const kShowAllModulesOpt
std::string const & parentageBranchName()
ProductList & productListUpdator()
void addDescendants(edm::BranchID const &branchID, std::set< edm::BranchID > &descendantBranchIDs, std::ostringstream &sout, std::map< edm::BranchID, std::set< edm::BranchID > > &parentToChildren) const
std::vector< std::string > findMatch_
std::map< ParameterSetID, ParameterSetBlob > ParameterSetMap
std::string const & productDescriptionBranchName()
static char const *const kExtendedDescendantsOpt
vpsettable const & vpsetTable() const
static char const *const kFileNameOpt
std::string const & BranchTypeToProductProvenanceBranchName(BranchType const &BranchType)
std::string const & eventTreeName()
std::string const & eventHistoryTreeName()
static char const *const kExtendedAncestorsOpt
bool insertMapped(value_type const &v)
table const & tbl() const
static ParentageRegistry * instance()
static std::string const triggerPaths
ParameterSet const & registerIt()
static std::string const source
tuple size
Write out results.
std::map< ProcessHistoryID, ProcessHistory > ProcessHistoryMap
std::string const & moduleDescriptionMapBranchName()
bool insertMapped(value_type const &v)
static Registry * instance()
static std::string topLevelPSet(std::string const &iName, edm::ParameterSet const &iProcessConfig, std::string const &iProcessName)
static char const *const kDumpPSetIDCommandOpt
static char const *const kExtendedDescendantsCommandOpt
void printErrors(std::ostream &os)
static char const *const kFindMatchOpt