File indexing completed on 2025-08-06 08:13:24
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #define FUN4ALL_RUNLAMBDAJETHUNTER_C
0011
0012
0013 #include <vector>
0014 #include <string>
0015
0016 #include <FROG.h>
0017 #include <fun4all/Fun4AllServer.h>
0018 #include <fun4all/Fun4AllDstInputManager.h>
0019 #include <g4main/Fun4AllDstPileupInputManager.h>
0020
0021 #include <slambdajethunter/SLambdaJetHunter.h>
0022
0023 #include "LambdaJetHunterOptions.h"
0024
0025
0026 using namespace std;
0027 using namespace SColdQcdCorrelatorAnalysis;
0028
0029
0030 R__LOAD_LIBRARY(libslambdajethunter.so)
0031 R__LOAD_LIBRARY(libscorrelatorutilities.so)
0032
0033
0034 static const int NEvtDefault = 10;
0035 static const int VerbDefault = 0;
0036 static const string SOutDefault = "test.root";
0037 static const vector<string> SInDefault = {
0038 "DST_GLOBAL_pythia8_Jet10_3MHz-0000000008-04075.root",
0039 "DST_TRUTH_pythia8_Jet10_3MHz-0000000008-04075.root"
0040 };
0041
0042
0043
0044
0045
0046 void Fun4All_RunLambdaJetHunter(
0047 const vector<string>& sInput = SInDefault,
0048 const string sOutput = SOutDefault,
0049 const int nEvents = NEvtDefault,
0050 const int verbosity = VerbDefault
0051 ) {
0052
0053
0054 SLambdaJetHunterConfig config = LambdaJetHunterOptions::GetConfig(verbosity, sOutput);
0055
0056
0057 gSystem -> Load("libg4dst.so");
0058 gSystem -> Load("libFROG.so");
0059
0060 FROG* frog = new FROG();
0061 Fun4AllServer* ffaServer = Fun4AllServer::instance();
0062 ffaServer -> Verbosity(verbosity);
0063
0064
0065 for (size_t iInput = 0; iInput < sInput.size(); iInput++) {
0066 Fun4AllDstInputManager* inManager = new Fun4AllDstInputManager("InputDstManager" + to_string(iInput));
0067 inManager -> AddFile(sInput.at(iInput));
0068 ffaServer -> registerInputManager(inManager);
0069 }
0070
0071
0072 SLambdaJetHunter* hunter = new SLambdaJetHunter(config);
0073 ffaServer -> registerSubsystem(hunter);
0074
0075
0076 ffaServer -> run(nEvents);
0077 ffaServer -> End();
0078 delete ffaServer;
0079
0080
0081 gSystem -> Exit(0);
0082 return;
0083
0084 }
0085
0086