Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-03 08:20:27

0001 #ifndef MACRO_TRKRDIAGNOSTICS_C
0002 #define MACRO_TRKRDIAGNOSTICS_C
0003 
0004 R__LOAD_LIBRARY(libTrackingDiagnostics.so)
0005 
0006 #include <Trkr_RecoInit.C>
0007 
0008 #include <trackingdiagnostics/KshortReconstruction.h>
0009 #include <trackingdiagnostics/helixResiduals.h>
0010 
0011 #include <fun4all/Fun4AllServer.h>
0012 
0013 
0014 
0015 void G4KshortReconstruction(const std::string outputfile)
0016 {
0017   Fun4AllServer* se         = Fun4AllServer::instance();
0018   KshortReconstruction *ksr = new KshortReconstruction();
0019   ksr->set_output_file(outputfile);
0020   se->registerSubsystem(ksr);
0021 }
0022 
0023 void seedResiduals(const std::string outputfile)
0024 {
0025   Fun4AllServer* se  = Fun4AllServer::instance();
0026 
0027   if(!Enable::MICROMEGAS)
0028     {
0029       std::cout<< "Micromegas not enabled"<<std::endl;
0030       return;
0031     }
0032 
0033   TrackingInit();
0034 
0035   helixResiduals *eval = new helixResiduals("eval_residuals");
0036   eval->set_output_file(outputfile);
0037   se->registerSubsystem(eval);
0038   
0039 }
0040 
0041 void Tracking_Diagnostics(const std::string outputfile)
0042 {
0043   G4KshortReconstruction(outputfile);
0044   seedResiduals(outputfile);
0045 }
0046 #endif