Back to home page

sPhenix code displayed by LXR

 
 

    


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

0001 #include "Vertex_XY.hh"
0002 
0003 void Vertex_XY(int run_no = 41981,
0004           int nEvents = 10)
0005 {
0006   //gSystem->ListLibraries();
0007 
0008   Fun4AllServer *se = Fun4AllServer::instance();
0009   se->Verbosity(1);
0010   recoConsts *rc = recoConsts::instance();
0011 
0012   //Enable::MVTX = true;
0013   Enable::INTT = true;
0014 
0015   //===============
0016  // conditions DB flags
0017   //===============
0018   Enable::CDB = true;
0019   // global tag
0020   rc->set_StringFlag("CDB_GLOBALTAG", CDB::global_tag);
0021   // 64 bit timestamp
0022   rc->set_uint64Flag("TIMESTAMP", CDB::timestamp);
0023   rc->set_IntFlag("RUNNUMBER", run_no );
0024 
0025   // Load ActsGeometry object
0026   TrackingInit();
0027 
0028   
0029   const string &input_file = Form("/sphenix/tg/tg01/commissioning/INTT/data/dst_files/2024/DST_physics_intt-000%d_no_hot_special.root", run_no);
0030   Fun4AllDstInputManager *in = new Fun4AllDstInputManager("Dst");
0031 
0032   auto dsts = GetDsts( run_no, false, "no_hot" );
0033   for( auto& dst : dsts )
0034     {
0035       in->fileopen( dst );
0036     }
0037   se->registerInputManager(in);
0038 
0039   InttXYVertexFinder* intt_xy = new InttXYVertexFinder();
0040   //  intt_xy->SetOutDirectory( "./results" );
0041   intt_xy->EnableQA( true );
0042   intt_xy->SetSaveHisto( true );
0043   intt_xy->EnableDrawHisto( true );
0044   se->registerSubsystem( intt_xy );
0045   
0046   string output = "InttAna_run" + to_string( run_no ) + ".root";
0047   // Fun4AllOutputManager *out = new Fun4AllDstOutputManager("out","test.root");
0048   // se->registerOutputManager(out);
0049 
0050   se->run(nEvents);
0051 
0052   se->End();
0053   delete se;
0054   //  gSystem->Exit(0);
0055   return;
0056 }