本文整理汇总了C++中TTree::Process方法的典型用法代码示例。如果您正苦于以下问题:C++ TTree::Process方法的具体用法?C++ TTree::Process怎么用?C++ TTree::Process使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TTree
的用法示例。
在下文中一共展示了TTree::Process方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
runExample() {
gROOT->ProcessLine(".exception");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/Reconstruction/Jet/JetAnalysisTools/ApplyJetResolutionSmearing/");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/Reconstruction/Jet/ApplyJetCalibration");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/Reconstruction/Jet/JetUncertainties");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/Reconstruction/Jet/JetResolution");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/Reconstruction/egamma/egammaAnalysis/egammaAnalysisUtils");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/PhysicsAnalysis/MuonID/MuonIDAnalysis/MuonMomentumCorrections");
gSystem->AddIncludePath("-I/usera/khoo/Work_2013/TestAreas/METUtil_dev/PhysicsAnalysis/TauID/TesUncertaintyProvider");
gSystem->AddLinkedLibs("-L/usera/khoo/Work_2013/TestAreas/METUtil_dev/InstallArea/x86_64-slc5-gcc43-opt/lib");
gSystem->AddLinkedLibs("-lApplyJetCalibrationLib");
gSystem->AddLinkedLibs("-lApplyJetResolutionSmearing");
gSystem->AddLinkedLibs("-lJetUncertainties");
gSystem->AddLinkedLibs("-lJetResolution");
gSystem->AddLinkedLibs("-lMuonMomentumCorrections");
gSystem->AddLinkedLibs("-legammaAnalysisUtils");
gSystem->AddLinkedLibs("-lTesUncertaintyProvider");
gSystem->AddLinkedLibs("-lMissingETUtilityLib");
gROOT->ProcessLine(".L EventReader.C+");
// TFile* rootfile = TFile::Open("mc12_8TeV.105200.McAtNloJimmy_CT10_ttbar/NTUP_JETMET.00955143._000216.root.1");
// TFile* rootfile = TFile::Open("/r02/atlas/khoo/sample_D3PD/CellOutSTVF_check/mc12_8TeV.107663.AlpgenJimmy_AUET2CTEQ6L1_ZmumuNp3.merge.NTUP_JETMET.e1218_s1469_s1470_r3542_r3549_p1344_tid01115626_00/NTUP_JETMET.01115626._000007.root.1");
// TFile* rootfile = TFile::Open("/r02/atlas/khoo/sample_D3PD/non_SUSY/user.sresconi.mc12_8TeV.147803.PowhegPythia8_AU2CT10_Wminenu.merge.AOD.e1169_s1469_s1470_r3542_r3549.R172test.JETMET.v6_EXT0.120607151801/user.sresconi.006202._00156.qcd.root");
// TFile* rootfile = TFile::Open("/r02/atlas/khoo/sample_D3PD/CellOutSTVF_check/mc12_8TeV.107663.AlpgenJimmy_AUET2CTEQ6L1_ZmumuNp3.merge.NTUP_SMWZ.e1218_s1469_s1470_r3542_r3549_p1328_tid01109228_00/NTUP_SMWZ.01109228._000004.root.1");
// TTree* physics = (TTree*) rootfile->Get("physics");
// physics->Process("Example.C+");
TFile* rootfile = TFile::Open("/r02/atlas/khoo/D3PD/ElJetOL/mc12_8TeV.107654.AlpgenJimmy_AUET2CTEQ6L1_ZeeNp4.merge.NTUP_SUSY.e1571_s1499_s1504_r3658_r3549_p1328/NTUP_SUSY.01116582._000001.root.1");
TTree* susy = (TTree*) rootfile->Get("susy");
susy->Process("Example.C+");
}
示例2: process
void process()
{
TFile *file = TFile::Open("20141008-3.root");
TTree *T = (TTree*)file->Get("thermoDAQ");
//T->Process("TempVsTime.C+");
//T->Process("Calibration.C+", "6500 6700 19000 19200");
//T->Process("CalTempVsTime.C+");
T->Process("Analysis.C+", "15 7 0 12850 13050");
}
示例3: runSimple
// Run all tests:
// - It is assumed that the trees are already generated (if not, call 'generateAll()')
// - The test will loop through the trees and generate the selector into the
// folder 'generated_selectors' (NameOfTree.h and NameOfTree.C).
// - The test will also try accessing the data in the tree. However, since the newly
// generated NameOfTree.C is empty, it uses a different .C file (located under
// 'test_selectors/NameOfTree.C'), which has been already filled with code accessing
// the data. (Regarding the header file, it needs no modification, so the newly
// generated one is used.)
void runSimple() {
const char *dirSaved = gSystem->pwd(); // Save working directory
// Loop through test trees
std::vector<std::string> trees = {"Tree", "TreeStruct"};
for (std::string const &treeName : trees)
{
fprintf(stderr, "Testing tree %s\n", treeName.c_str());
TFile f(("./trees/" + treeName + ".root").c_str()); // Load file
TTree *t = (TTree*)f.Get(treeName.c_str()); // Load tree
gSystem->cd("./generated_selectors"); // Go to gen. folder
t->MakeSelector(); // Generate selector
gSystem->cd(".."); // Go back
t->Process(("./test_selectors/" + treeName + ".C").c_str()); // Run (pre-filled) selector
}
gSystem->cd(dirSaved); // Restore working directory
}
示例4:
runExample() {
gSystem->AddIncludePath("-I/usera/khoo/atlas/MetUtil_dev/testarea/Reconstruction/Jet/JetUncertainties");
gSystem->AddIncludePath("-I/usera/khoo/atlas/MetUtil_dev/testarea/Reconstruction/Jet/JetResolution");
gSystem->AddIncludePath("-I/usera/khoo/atlas/MetUtil_dev/testarea/Reconstruction/egamma/egammaAnalysis/egammaAnalysisUtils");
gSystem->AddIncludePath("-I/usera/khoo/atlas/MetUtil_dev/testarea/PhysicsAnalysis/MuonID/MuonIDAnalysis/MuonMomentumCorrections");
gSystem->AddLinkedLibs("-L/usera/khoo/atlas/MetUtil_dev/testarea/InstallArea/x86_64-slc5-gcc43-opt/lib");
gSystem->AddLinkedLibs("-lJetUncertainties");
gSystem->AddLinkedLibs("-lJetResolution");
gSystem->AddLinkedLibs("-lMuonMomentumCorrections");
gSystem->AddLinkedLibs("-legammaAnalysisUtils");
gSystem->AddLinkedLibs("-lMissingETUtilityLib");
gROOT->ProcessLine(".L EventReader.C+");
TFile* rootfile = TFile::Open("mc11_7TeV.105200.T1_McAtNlo_Jimmy.NTUP_JETMET.root");
// TFile* rootfile = TFile::Open("data12_8TeV.00201383.physics_JetTauEtmiss.NTUP_SUSY.p981.root");
TTree* qcd = (TTree*) rootfile->Get("qcd");
qcd->Process("Example.C+");
}