Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-06 08:13:28

0001 #pragma once
0002 #if ROOT_VERSION_CODE >= ROOT_VERSION(6,00,0)
0003 #include <fun4all/SubsysReco.h>
0004 #include <fun4all/Fun4AllServer.h>
0005 #include <fun4all/Fun4AllInputManager.h>
0006 #include <fun4all/Fun4AllDstInputManager.h>
0007 
0008 #include </gpfs/mnt/gpfs02/sphenix/user/lebedev/mdc/analysis/install/include/sphanalysis/sPHAnalysis.h>
0009 #include </gpfs/mnt/gpfs02/sphenix/user/lebedev/mdc/analysis/install/include/eventmix/sPHElectronPair.h>
0010 #include </gpfs/mnt/gpfs02/sphenix/user/lebedev/mdc/analysis/install/include/eventmix/sPHElectronPairv1.h>
0011 #include </gpfs/mnt/gpfs02/sphenix/user/lebedev/mdc/analysis/install/include/eventmix/sPHElectronPairContainer.h>
0012 #include </gpfs/mnt/gpfs02/sphenix/user/lebedev/mdc/analysis/install/include/eventmix/sPHElectronPairContainerv1.h>
0013 
0014 R__LOAD_LIBRARY(libfun4all.so)
0015 R__LOAD_LIBRARY(libeventmix.so)
0016 R__LOAD_LIBRARY(libsphanalysis.so)
0017 #endif
0018 
0019 void runanapythiaupsilon()
0020 {
0021   gSystem->Load("libg4dst");
0022   gSystem->Load("libeventmix");
0023   gSystem->Load("libsphanalysis");
0024 
0025   char outfilename[99];
0026   char infilename[99];
0027   //sprintf(outfilename,"/sphenix/user/lebedev/mdc/embedmb_withpileup_bb.root");
0028   sprintf(outfilename,"test.root");
0029   cout << "output file: " << outfilename << endl;
0030 
0031   Fun4AllServer *se = Fun4AllServer::instance();
0032   sPHAnalysis *ana = new sPHAnalysis("sPHAnalysis",outfilename);
0033   ana->set_whattodo(2);
0034   se->registerSubsystem(ana);
0035 
0036   Fun4AllInputManager *in = new Fun4AllDstInputManager("in");
0037   //in->fileopen(fname);
0038   se->registerInputManager(in);
0039   //in->AddListFile("pions3.txt");
0040   //in->AddListFile("kaons.txt");
0041   in->AddFile("/sphenix/sim/sim01/sphnxpro/MDC1/embed/pythiaupsilonDST_pythia6-0000000000-00101.root");
0042 
0043 //  for(int i=0; i<10; i++) {
0044 //    sprintf(infilename,"/sphenix/sim/sim01/sphnxpro/MDC1/embed/embedDST_sHijing_0_20fm_50kHz_bkg_0_20fm-0000000001-0%d.root",kkk+i);
0045 //    cout << "in:  " << infilename << endl;
0046 //    in->AddFile(infilename);
0047 //  }
0048 
0049   se->run();
0050   se->End();
0051 }
0052