Skip to content

Commit

Permalink
Merge pull request #41746 from brunolopesbr2/remove-genrefittedSAmuons
Browse files Browse the repository at this point in the history
Remove gen refitted SA muons
  • Loading branch information
cmsbuild authored May 26, 2023
2 parents 4d89be3 + 1ae3d6c commit 3ed7ae6
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 4 deletions.
20 changes: 18 additions & 2 deletions HLTriggerOffline/Exotica/src/HLTExoticaPlotter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,15 @@ void HLTExoticaPlotter::bookHist(DQMStore::IBooker &iBooker,
}

h->Sumw2();
_elements[name] = iBooker.book1D(name, h);

if (source == "gen") {
if (objType != "refittedStandAloneMuons") {
_elements[name] = iBooker.book1D(name, h);
}
} else {
_elements[name] = iBooker.book1D(name, h);
}

// LogDebug("ExoticaValidation") << " booked histo
// with name " << name << "\n"
// << " at location " <<
Expand All @@ -265,6 +273,14 @@ void HLTExoticaPlotter::fillHist(const bool &passTrigger,
std::string name = source + objType + variable + "_" + _hltPath;

LogDebug("ExoticaValidation") << "In HLTExoticaPlotter::fillHist()" << name << " " << value;
_elements[name]->Fill(value);

if (source == "gen") {
if (objType != "refittedStandAloneMuons") {
_elements[name]->Fill(value);
}
} else {
_elements[name]->Fill(value);
}

LogDebug("ExoticaValidation") << "In HLTExoticaPlotter::fillHist()" << name << " worked";
}
20 changes: 18 additions & 2 deletions HLTriggerOffline/Exotica/src/HLTExoticaSubAnalysis.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1104,7 +1104,15 @@ void HLTExoticaSubAnalysis::bookHist(DQMStore::IBooker &iBooker,
// This is the trick, that takes a normal TH1F and puts it in in the DQM
// machinery. Seems to be easy!
// Updated to use the new iBooker machinery.
_elements[name] = iBooker.book1D(name, h);

if (source == "gen") {
if (objType != "refittedStandAloneMuons") {
_elements[name] = iBooker.book1D(name, h);
}
} else {
_elements[name] = iBooker.book1D(name, h);
}

delete h;
}

Expand All @@ -1118,7 +1126,15 @@ void HLTExoticaSubAnalysis::fillHist(const std::string &source,
std::string name = source + objType + variable;

LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::fillHist() " << name << " " << value;
_elements[name]->Fill(value);

if (source == "gen") {
if (objType != "refittedStandAloneMuons") {
_elements[name]->Fill(value);
}
} else {
_elements[name]->Fill(value);
}

LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::fillHist() " << name << " worked";
}

Expand Down
8 changes: 8 additions & 0 deletions HLTriggerOffline/Exotica/test/run_all.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import os
#Create a list of samples to run, e.g.:
#samples = ["DisplacedSUSY","EtaBToJpsiJpsi","H125GGgluonfusion","MinBias","QCD_FlatPt_15_3000HS","QCD_Pt_1800_2400","SingleMuPt1000","SingleMuPt100","SingleMuPt10","TTbarToDilepton","TTbar","Upsilon1SToMuMu","WToLNu","WprimeToLNu","ZEE","ZMM","ZTT","ZpTT","ZpToEE"]

samples = []

for sample in samples:
os.system("cmsRun hltExoticaValidator_cfg.py _input "+sample+"; cmsRun hltExoticaPostProcessor_cfg.py _input "+sample+"; cp DQM_V0001_R000000001__Global__CMSSW_X_Y_Z__RECO.root correctVal_DQM_"+sample+".root; root -l -b -q \"saveDQMHistograms.C(\\\"correctVal_DQM_"+sample+".root\\\",\\\"correct"+sample+"\\\")\";")

0 comments on commit 3ed7ae6

Please sign in to comment.