32 |
// error "Cannot find InclinationInfo.h" update your DV installation |
// error "Cannot find InclinationInfo.h" update your DV installation |
33 |
#include <RunInfo.h> |
#include <RunInfo.h> |
34 |
#include <GLTables.h> |
#include <GLTables.h> |
35 |
|
#include <ExtTrack.h> |
36 |
|
|
37 |
|
|
38 |
#include <TTree.h> |
#include <TTree.h> |
40 |
#include <TChain.h> |
#include <TChain.h> |
41 |
#include <TChainElement.h> |
#include <TChainElement.h> |
42 |
#include <TFile.h> |
#include <TFile.h> |
43 |
|
#include <TTimeStamp.h> |
44 |
#include <TList.h> |
#include <TList.h> |
45 |
#include <TKey.h> |
#include <TKey.h> |
46 |
#include <TSystemFile.h> |
#include <TSystemFile.h> |
227 |
|
|
228 |
private: |
private: |
229 |
|
|
230 |
|
ExtTrack* trk_ext_track; |
231 |
TrkTrack* trk_track; |
TrkTrack* trk_track; |
232 |
CaloTrkVar* calo_track; |
CaloTrkVar* calo_track; |
233 |
ToFTrkVar* tof_track; |
ToFTrkVar* tof_track; |
242 |
|
|
243 |
PamTrack(); |
PamTrack(); |
244 |
PamTrack(TrkTrack* , CaloTrkVar* , ToFTrkVar*, OrbitalInfoTrkVar* ); |
PamTrack(TrkTrack* , CaloTrkVar* , ToFTrkVar*, OrbitalInfoTrkVar* ); |
245 |
|
PamTrack(ExtTrack* , CaloTrkVar* , ToFTrkVar*, OrbitalInfoTrkVar* ); |
246 |
PamTrack(const PamTrack&); |
PamTrack(const PamTrack&); |
247 |
~PamTrack(){ Delete(); }; |
~PamTrack(){ Delete(); }; |
248 |
|
|
249 |
void Clear(); |
void Clear(Option_t *option); |
250 |
void Clear(Option_t *option){Clear();}; |
void Clear(){Clear("");}; |
251 |
void Delete(); |
void Delete(); |
252 |
|
|
253 |
Bool_t IsSolved(){if ((pscore-iscore)>0) return true; return false;}; |
Bool_t IsSolved(){if ((pscore-iscore)>0) return true; return false;}; |
257 |
void SetPScore(Int_t p){pscore=p;}; |
void SetPScore(Int_t p){pscore=p;}; |
258 |
void SetIScore(Int_t i){iscore=i;}; |
void SetIScore(Int_t i){iscore=i;}; |
259 |
|
|
260 |
|
ExtTrack* GetExtTrack(){return trk_ext_track;}; |
261 |
TrkTrack* GetTrkTrack(){return trk_track;}; |
TrkTrack* GetTrkTrack(){return trk_track;}; |
262 |
CaloTrkVar* GetCaloTrack(){return calo_track;}; |
CaloTrkVar* GetCaloTrack(){return calo_track;}; |
263 |
ToFTrkVar* GetToFTrack(){return tof_track;}; |
ToFTrkVar* GetToFTrack(){return tof_track;}; |
264 |
OrbitalInfoTrkVar* GetOrbitalInfoTrack(){return orb_track;}; |
OrbitalInfoTrkVar* GetOrbitalInfoTrack(){return orb_track;}; |
265 |
|
|
266 |
ClassDef(PamTrack,2); |
ClassDef(PamTrack,3); |
267 |
}; |
}; |
268 |
|
|
269 |
/** |
/** |
299 |
Long64_t il0entry; ///< entry of level0 file in selection list |
Long64_t il0entry; ///< entry of level0 file in selection list |
300 |
TChain* run_tree; |
TChain* run_tree; |
301 |
TTree* run_tree_clone; |
TTree* run_tree_clone; |
302 |
|
TChain* proc_tree; |
303 |
|
TTree* proc_tree_clone; |
304 |
TChain* sel_tree; |
TChain* sel_tree; |
305 |
TTree* sel_tree_clone; |
TTree* sel_tree_clone; |
306 |
int *irunoffset; |
int *irunoffset; |
307 |
GL_TIMESYNC *gltsync; // Emiliano |
GL_TIMESYNC *gltsync; // Emiliano |
308 |
Bool_t fUpdateRunInfo; // Emiliano |
Bool_t fUpdateRunInfo; // Emiliano |
309 |
|
Bool_t fUseDBinRunInfo; // Emiliano |
310 |
|
|
311 |
|
Bool_t fDiscarded; ///< true if any file from a list is missing |
312 |
|
TString customString; ///< String passed to ProcessingInfo |
313 |
|
|
314 |
// ------------------------------------------- |
// ------------------------------------------- |
315 |
// variables to store total live and dead time |
// variables to store total live and dead time |
354 |
TrkHough* trkh_obj; |
TrkHough* trkh_obj; |
355 |
CaloLevel1* calo1_obj; |
CaloLevel1* calo1_obj; |
356 |
CaloLevel2* calo2_obj; |
CaloLevel2* calo2_obj; |
357 |
ToFLevel2* tof_obj; |
ToFLevel2* tof2_obj; |
358 |
TrigLevel2* trig_obj; |
TrigLevel2* trig_obj; |
359 |
S4Level2* s4_obj; |
S4Level2* s4_obj; |
360 |
NDLevel2* nd_obj; |
NDLevel2* nd_obj; |
361 |
AcLevel2* ac_obj; |
AcLevel2* ac_obj; |
362 |
OrbitalInfo* orb_obj; |
OrbitalInfo* orb2_obj; |
363 |
GL_RUN* run_obj; |
GL_RUN* run_obj; |
364 |
SoftInfo* soft_obj; // Emiliano |
SoftInfo* soft_obj; // Emiliano |
365 |
|
ProcInfo* proc_obj; //EM |
366 |
|
|
367 |
|
|
368 |
|
|
369 |
|
Int_t extAlgFlag; |
370 |
|
|
371 |
|
TClonesArray* trk_ext_obj; |
372 |
|
TClonesArray* trk_ext_nuc_obj; |
373 |
|
TClonesArray* trk_nuc_obj; |
374 |
|
|
375 |
|
|
376 |
|
TClonesArray* calo_ext_obj; |
377 |
|
TClonesArray* calo_ext_nuc_obj; |
378 |
|
TClonesArray* calo_nuc_obj; |
379 |
|
|
380 |
|
TClonesArray* tof_ext_obj; |
381 |
|
TClonesArray* tof_ext_nuc_obj; |
382 |
|
TClonesArray* tof_nuc_obj; |
383 |
|
|
384 |
|
TClonesArray* orb_ext_obj; |
385 |
|
TClonesArray* orb_ext_nuc_obj; |
386 |
|
TClonesArray* orb_nuc_obj; |
387 |
|
|
388 |
|
|
389 |
|
TrkLevel2* trk2_nuc_obj; |
390 |
|
CaloLevel2* calo2_nuc_obj; |
391 |
|
ToFLevel2* tof2_nuc_obj; |
392 |
|
OrbitalInfo* orb2_nuc_obj; |
393 |
|
|
394 |
|
|
395 |
|
|
396 |
// -------------------------------------------- |
// -------------------------------------------- |
397 |
// variables to handle GP |
// variables to handle GP |
403 |
// ----------------------------------- |
// ----------------------------------- |
404 |
TClonesArray *tsorted; |
TClonesArray *tsorted; |
405 |
TClonesArray *timage; |
TClonesArray *timage; |
406 |
|
TClonesArray *text; //array of pamtrack objects built from extended algorythm |
407 |
|
TClonesArray *tsorted_nuc; |
408 |
|
TClonesArray *timage_nuc; |
409 |
|
TClonesArray *text_nuc; //array of pamtrack objects built from extended algorythm |
410 |
|
|
411 |
PamTrack *track; //store the last required |
PamTrack *track; //store the last required |
412 |
TString howtosort; |
TString howtosort; |
413 |
Float_t sortthr; |
Float_t sortthr; |
414 |
|
|
415 |
Bool_t issorted; // true if the current event has already been sorted with the current sort criteria |
Bool_t issorted; // true if the current event has already been sorted with the current sort criteria |
416 |
Long64_t lastsorted; // the last event whose tracks has been sorted |
Long64_t lastsorted; // the last event whose tracks has been sorted |
417 |
|
|
418 |
|
|
419 |
|
Bool_t issorted_new; // true if the current event has already been sorted with the current sort criteria |
420 |
|
Long64_t lastsorted_new; // the last event whose tracks has been sorted |
421 |
|
|
422 |
// -------------------------------------- |
// -------------------------------------- |
423 |
// flags to load level0-1-2 trees/braches |
// flags to load level0-1-2 trees/braches |
424 |
// -------------------------------------- |
// -------------------------------------- |
442 |
|
|
443 |
Bool_t GP; //GP simulation tree |
Bool_t GP; //GP simulation tree |
444 |
|
|
445 |
|
|
446 |
|
Bool_t EXT;//get tracks from extended tracking algorythm |
447 |
|
Bool_t NUC;//get tracks from nuclei algorythm |
448 |
|
|
449 |
|
Bool_t PROC;//EM |
450 |
|
|
451 |
|
const char* trkAlg; |
452 |
|
|
453 |
// ----------- |
// ----------- |
454 |
// other flags |
// other flags |
455 |
// ----------- |
// ----------- |
500 |
|
|
501 |
void SkipRunInfoUpdate(); // Emiliano |
void SkipRunInfoUpdate(); // Emiliano |
502 |
void DoRunInfoUpdate(){fUpdateRunInfo = true;}; // [default] Emiliano |
void DoRunInfoUpdate(){fUpdateRunInfo = true;}; // [default] Emiliano |
503 |
|
void UseDBinRunInfo(){fUseDBinRunInfo = true;}; // [default] Emiliano |
504 |
|
void NoDBinRunInfo(){fUseDBinRunInfo = false;}; // EM |
505 |
void NoDBconnections(){SkipRunInfoUpdate();}; // Emiliano |
void NoDBconnections(){SkipRunInfoUpdate();}; // Emiliano |
506 |
|
|
507 |
void CreateCloneTrees0(TChain *fChain, TFile* file); |
void CreateCloneTrees0(TChain *fChain, TFile* file); |
524 |
Long64_t GetEntries(){return pam_tree->GetEntries();}; |
Long64_t GetEntries(){return pam_tree->GetEntries();}; |
525 |
TChain* GetPamTree(){return pam_tree;}; |
TChain* GetPamTree(){return pam_tree;}; |
526 |
TChain* GetRunTree(){return run_tree;}; |
TChain* GetRunTree(){return run_tree;}; |
527 |
|
TChain* GetProcessingInfoTree(){return proc_tree;}; |
528 |
TTree* GetYodaTree(); |
TTree* GetYodaTree(); |
529 |
|
|
530 |
TFile* GetYodaFile(){return l0_file;}; // can be useful to know the name of level0 file we are using or similar things |
TFile* GetYodaFile(){return l0_file;}; // can be useful to know the name of level0 file we are using or similar things |
555 |
TrkHough *GetTrkHough() { return trkh_obj; }; |
TrkHough *GetTrkHough() { return trkh_obj; }; |
556 |
CaloLevel1 *GetCaloLevel1() { return calo1_obj;}; |
CaloLevel1 *GetCaloLevel1() { return calo1_obj;}; |
557 |
CaloLevel2 *GetCaloLevel2() { return calo2_obj;}; |
CaloLevel2 *GetCaloLevel2() { return calo2_obj;}; |
558 |
ToFLevel2 *GetToFLevel2() { return tof_obj; }; |
ToFLevel2 *GetToFLevel2() { return tof2_obj; }; |
559 |
TrigLevel2 *GetTrigLevel2() { return trig_obj; }; |
TrigLevel2 *GetTrigLevel2() { return trig_obj; }; |
560 |
S4Level2 *GetS4Level2() { return s4_obj; }; |
S4Level2 *GetS4Level2() { return s4_obj; }; |
561 |
NDLevel2 *GetNDLevel2() { return nd_obj; }; |
NDLevel2 *GetNDLevel2() { return nd_obj; }; |
562 |
AcLevel2 *GetAcLevel2() { return ac_obj; }; |
AcLevel2 *GetAcLevel2() { return ac_obj; }; |
563 |
OrbitalInfo *GetOrbitalInfo(){ return orb_obj; }; |
OrbitalInfo *GetOrbitalInfo(){ return orb2_obj; }; |
564 |
GL_RUN *GetRunInfo() { return run_obj; }; |
GL_RUN *GetRunInfo() { return run_obj; }; |
565 |
SoftInfo *GetSoftInfo() { return soft_obj; }; // Emiliano |
SoftInfo *GetSoftInfo() { return soft_obj; }; // Emiliano |
566 |
|
ProcInfo *GetProcInfo() { return proc_obj; }; // Emiliano |
567 |
GPamela *GetGPamela() { return gp_obj; }; |
GPamela *GetGPamela() { return gp_obj; }; |
568 |
|
|
569 |
// ============================================== |
// ============================================== |
587 |
void SortTracks(); //assign value to variable sorted_tracks |
void SortTracks(); //assign value to variable sorted_tracks |
588 |
// TRefArray* GetTracks(); //return sorted_tracks |
// TRefArray* GetTracks(); //return sorted_tracks |
589 |
TClonesArray* GetTracks(); //return sorted_tracks |
TClonesArray* GetTracks(); //return sorted_tracks |
590 |
PamTrack* GetTrack(int); |
PamTrack* GetTrackOld(int); |
591 |
PamTrack* GetTrackImage(int); |
PamTrack* GetTrackImageOld(int); |
592 |
void SetSortingMethod(TString how); |
PamTrack* GetTrack(int i){ return GetTrackOld(i); }; |
593 |
|
PamTrack* GetTrackImage(int i){ return GetTrackImageOld(i); }; |
594 |
|
void SetSortingMethod(TString how); |
595 |
TString GetSortingMethod(){return howtosort;}; |
TString GetSortingMethod(){return howtosort;}; |
596 |
void SetNucleiSortingThreshold(Float_t nucleithr){ sortthr = nucleithr; return;}; |
void SetNucleiSortingThreshold(Float_t nucleithr){ sortthr = nucleithr; return;}; |
597 |
Float_t GetNucleiSortingThreshold(){ return sortthr;}; |
Float_t GetNucleiSortingThreshold(){ return sortthr;}; |
598 |
|
|
599 |
|
|
600 |
|
|
601 |
|
|
602 |
|
// ================================= |
603 |
|
// methods to handle new tracking algorythms |
604 |
|
// ================================= |
605 |
|
/* Int_t GetTrackingAlgorythmFlag(){return extAlgFlag;}; */ |
606 |
|
/* void SetTrackingAlgorythm(const char * alg); */ |
607 |
|
/* const char* GetTrackingAlgorythm(); */ |
608 |
|
|
609 |
|
Int_t GetNTracks(const char*); |
610 |
|
PamTrack* GetTrack(int,const char*); |
611 |
|
PamTrack* GetTrackImage(int, const char*); |
612 |
|
|
613 |
|
|
614 |
|
/* Int_t GetNTracks(){return GetNTracks(trkAlg); }; */ |
615 |
|
/* PamTrack* GetTrack(int i) { return GetTrack(i,trkAlg); }; */ |
616 |
|
/* PamTrack* GetTrackImage(int i){ return GetTrackImage(i,trkAlg); }; */ |
617 |
|
|
618 |
|
void SortTracksNew(); //assign value to variable sorted_tracks |
619 |
|
|
620 |
|
|
621 |
// ================================= |
// ================================= |
622 |
// other methods |
// other methods |
623 |
// ================================= |
// ================================= |
650 |
|
|
651 |
Bool_t IsRUN(){return RUN;}; |
Bool_t IsRUN(){return RUN;}; |
652 |
|
|
653 |
|
Bool_t IsEXT(){return EXT;}; |
654 |
|
Bool_t IsNUC(){return NUC;}; |
655 |
|
|
656 |
Bool_t IsGood(Bool_t strict=true); |
Bool_t IsGood(Bool_t strict=true); |
657 |
|
|
658 |
Int_t IsSELLI(){return SELLI;}; //trees of selected events (there is a selection list) |
Int_t IsSELLI(){return SELLI;}; //trees of selected events (there is a selection list) |
659 |
void SetSELLI(Int_t selli){SELLI=selli;}; |
void SetSELLI(Int_t selli){SELLI=selli;}; |
660 |
|
|
661 |
|
Bool_t IsPROC(){return PROC;};//EM |
662 |
|
|
663 |
|
Bool_t HasDiscardedFiles(){return fDiscarded;}; ///< true if something went wrong and not all files were processed |
664 |
|
|
665 |
Bool_t IsGP(){return ISGP;}; |
Bool_t IsGP(){return ISGP;}; |
666 |
|
|
667 |
void SetGP(Bool_t tt){ISGP=tt;}; |
void SetGP(Bool_t tt){ISGP=tt;}; |
668 |
|
|
669 |
void SetDebug(Bool_t set){ DBG=set; TrkParams::SetVerboseMode(); }; |
void SetDebug(Bool_t set){ DBG=set; TrkParams::SetVerboseMode(); }; |
670 |
|
|
671 |
|
void SetCustomString(TString cus){customString=cus;}; |
672 |
ClassDef(PamLevel2,2); |
TString GetCustomString(){return customString;}; |
673 |
|
|
674 |
|
ClassDef(PamLevel2,4); |
675 |
}; |
}; |
676 |
|
|
677 |
//=============================================================================================== |
//=============================================================================================== |