main_proc_test.C 514 B

1234567891011121314151617181920212223242526272829
  1. //#include "FlowANA.C"
  2. #include "FlowANA_test.C"
  3. #include <TStopwatch.h>
  4. #include <TChain.h>
  5. #include <iostream>
  6. #include <fstream>
  7. void main_proc_test(const char *filelist, char *output)
  8. {
  9. TStopwatch timer;
  10. timer.Start();
  11. TChain *chain = new TChain("mctree");
  12. std::ifstream file(filelist);
  13. std::string str;
  14. while (std::getline(file,str))
  15. {
  16. chain->Add(str.c_str());
  17. }
  18. FlowANA *t = new FlowANA(chain);
  19. t->ana_init(output);
  20. t->Loop();
  21. t->ana_end();
  22. timer.Stop();
  23. timer.Print();
  24. }