Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-06 08:18:41

0001 #ifndef bcocheck_H__
0002 #define bcocheck_H__
0003 
0004 // std headers
0005 #include <array>
0006 #include <filesystem>
0007 #include <iomanip>  // setw, setfill
0008 #include <iostream>
0009 #include <vector>
0010 
0011 #include <fstream>
0012 #include <iostream>
0013 #include <set>
0014 #include <string>
0015 #include <vector>
0016 
0017 // ROOT headers
0018 #include <TCanvas.h>
0019 #include <TFile.h>
0020 #include <TGraph.h>
0021 #include <TH1.h>
0022 #include <TH2.h>
0023 #include <TLegend.h>
0024 #include <TLine.h>
0025 #include <TObject.h>
0026 #include <TPaveStats.h>
0027 #include <TROOT.h>
0028 #include <TStyle.h>
0029 #include <TSystem.h>
0030 #include <TTree.h>
0031 
0032 // Fun4All headers
0033 #include <fun4all/SubsysReco.h>
0034 
0035 #include <fun4all/Fun4AllHistoManager.h>
0036 #include <fun4all/Fun4AllReturnCodes.h>
0037 
0038 #include <ffarawobjects/InttRawHit.h>
0039 #include <ffarawobjects/InttRawHitContainer.h>
0040 
0041 #include <trackbase/InttEventInfo.h>
0042 #include <trackbase/InttEventInfov1.h>
0043 
0044 #include <phool/PHCompositeNode.h>
0045 #include <phool/getClass.h>
0046 
0047 class PHCompositeNode;
0048 
0049 class bcocheck : public SubsysReco
0050 {
0051  public:
0052   explicit bcocheck(const std::string &name = "bcocheck", const int run_num = 0, const int felix_num = 0);
0053 
0054   ~bcocheck() override = default;
0055 
0056   int Init(PHCompositeNode *) override;
0057 
0058   int InitRun(PHCompositeNode *) override;
0059 
0060   /// SubsysReco event processing method
0061   int process_event(PHCompositeNode *) override;
0062 
0063   int End(PHCompositeNode *) override;
0064 
0065   // int SetHistBin(std::string type);
0066  private:
0067   // general variables
0068   int run_num_ = 0;
0069   int felix_num_ = 0;
0070   static const int kFelix_num_ = 8;     // the number of our FELIX server
0071   static const int kFee_num_ = 14;      // the number of half-ladders in a single FELIX server
0072   static const int kChip_num_ = 26;     // the number of chip in a half-ladder
0073   static const int kChan_num_ = 128;    // the number of channel in a single chip
0074   static const int kFirst_pid_ = 3001;  // the first pid (packet ID), which means intt0
0075   static const int divimul = 10;
0076 
0077   int ievent_ = 0;
0078   TFile *tf_output_[kFelix_num_] = {};
0079 
0080   TH1D *h_full_bco[kFelix_num_] = {};
0081 
0082   void DrawHists();
0083 };
0084 #endif