2022-06-08 14:43:03 -04:00
|
|
|
///#include "armory/evtReader.h"
|
2022-06-06 19:57:17 -04:00
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
///evtReader * evt = new evtReader("run-0238-00.evt", true);
|
|
|
|
|
|
|
|
#include "peachCake.C+"
|
2022-06-06 19:57:17 -04:00
|
|
|
|
|
|
|
void script() {
|
2022-06-22 19:33:20 -04:00
|
|
|
|
2022-06-06 19:57:17 -04:00
|
|
|
|
2022-06-22 19:33:20 -04:00
|
|
|
int runNum = 250;
|
2022-06-08 14:43:03 -04:00
|
|
|
|
2022-05-24 18:21:12 -04:00
|
|
|
TChain * chain = new TChain("tree");
|
2022-06-22 19:33:20 -04:00
|
|
|
//chain->Add(Form("root_data/run-%04d-*.root", runNum));
|
2022-05-24 18:21:12 -04:00
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
//chain->Add("root_data/run-0237-*.root");
|
|
|
|
//chain->Add("root_data/run-0238-*.root");
|
|
|
|
//chain->Add("root_data/run-0241-*.root");
|
2022-06-22 19:33:20 -04:00
|
|
|
|
|
|
|
// new beam
|
2022-06-08 14:43:03 -04:00
|
|
|
//chain->Add("root_data/run-0246-*.root");
|
2022-06-22 19:33:20 -04:00
|
|
|
//chain->Add("root_data/run-0247-*.root");
|
|
|
|
//chain->Add("root_data/run-0248-*.root");
|
|
|
|
//chain->Add("root_data/run-0249-*.root");
|
|
|
|
//chain->Add("root_data/run-0250-*.root");
|
|
|
|
//chain->Add("root_data/run-0251-*.root");
|
|
|
|
//chain->Add("root_data/run-0252-*.root");
|
|
|
|
//chain->Add("root_data/run-0253-*.root");
|
|
|
|
//chain->Add("root_data/run-0254-*.root");
|
|
|
|
//chain->Add("root_data/run-0257-*.root");
|
|
|
|
//chain->Add("root_data/run-0258-*.root");
|
|
|
|
//chain->Add("root_data/run-0259-*.root");
|
|
|
|
//chain->Add("root_data/run-0261-*.root");
|
|
|
|
//chain->Add("root_data/run-0262-*.root");
|
|
|
|
//chain->Add("root_data/run-0263-*.root");
|
|
|
|
//chain->Add("root_data/run-0264-*.root");
|
|
|
|
//chain->Add("root_data/run-0269-*.root");
|
|
|
|
//chain->Add("root_data/run-0270-*.root");
|
|
|
|
chain->Add("root_data/run-0271-*.root");
|
2022-06-08 14:43:03 -04:00
|
|
|
|
2022-06-22 19:33:20 -04:00
|
|
|
int nFile = chain->GetListOfFiles()->GetEntries();
|
|
|
|
|
|
|
|
printf("================================ num of Files : %d \n", nFile);
|
2022-06-08 14:43:03 -04:00
|
|
|
|
2022-06-22 19:33:20 -04:00
|
|
|
if( nFile == 0 ) return;
|
2022-06-08 14:43:03 -04:00
|
|
|
|
|
|
|
bool isSaveNewTree = false;
|
2022-06-22 19:33:20 -04:00
|
|
|
|
|
|
|
TString histRootFileName = "";// Form("PID_%03d.root", runNum);
|
|
|
|
|
|
|
|
TString pidCorrFileName = "correction_PID.dat";
|
2022-05-24 18:21:12 -04:00
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
chain->GetListOfFiles()->Print();
|
2022-06-22 19:33:20 -04:00
|
|
|
|
|
|
|
printf("================================\n");
|
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
peachCake * selector = new peachCake();
|
|
|
|
selector->SaveNewTree(isSaveNewTree);
|
2022-06-22 19:33:20 -04:00
|
|
|
selector->SetPIDCorrectionFile(pidCorrFileName);
|
|
|
|
selector->SetHistRootFileName(histRootFileName);
|
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
chain->Process(selector, "");
|
2022-06-06 19:57:17 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
2022-06-22 19:33:20 -04:00
|
|
|
|
2022-06-08 14:43:03 -04:00
|
|
|
///gROOT->ProcessLine("armory/nsclEvtReader.h");
|
|
|
|
///evt->ReadBlock(2);
|
2022-06-22 19:33:20 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-05-24 18:21:12 -04:00
|
|
|
}
|