Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Blinder.h

Go to the documentation of this file.
00001 
00002 // $Id: Blinder.h,v 1.4 2005/06/20 15:24:32 tagg Exp $
00003 //
00004 // Module to apply blindness for physics analysis.
00005 //
00006 // Blinder::Ana returns kPassed for events that should be in the open dataset
00007 // and kFailed for events that should be only in the blind dataset.
00008 //
00009 // It returns kPassed for all events in the ND, and uses
00010 // the algorithm presented at the Jan 2005 collab meeting to
00011 // select events from the FD.
00012 //
00013 // Nathaniel Tagg
00014 // n.tagg1@physics.ox.ac.uk
00016 #ifndef BLINDER_H
00017 #define BLINDER_H
00018 
00019 #include "JobControl/JobCModule.h"
00020 
00021 class RawDigitDataBlock;
00022 class TFile;
00023 class TNtuple;
00024 class REROOT_NeuKin;
00025 class TRandom;
00026 
00027 class Blinder : public JobCModule
00028 {
00029 public:
00030   Blinder();
00031   ~Blinder();
00032 
00033 public:
00034   // Analysis and Reconstruction methods
00035   virtual JobCResult Ana(const MomNavigator* mom);
00036   virtual JobCResult Reco(MomNavigator* mom);
00037 
00038   // Module configuration
00039   const Registry& DefaultConfig() const;
00040   void            Config(const Registry& r);
00041 
00042 
00043 private:
00044   Bool_t GetInfo(const MomNavigator* mom,
00045                  Int_t &run,
00046                  Int_t &snarl,
00047                  Int_t &epoch,
00048                  Float_t &length,
00049                  Float_t &energy);
00050 
00051   const REROOT_NeuKin* GetTruth(const MomNavigator* mom);
00052 
00053   // Config data:
00054   Int_t fSeed;
00055 
00056   // The actual work is done by:
00057 
00058   class BlindingFunction {
00059   public:
00060     BlindingFunction();
00061     void    SetParameters( TRandom* paramChooser, Int_t seed );
00062     Float_t EventBlindProb( Float_t eventLength, Float_t eventEnergy );
00063   
00064     Float_t fLFreq;
00065     Float_t fEFreq;
00066     Float_t fLPhase;
00067     Float_t fEPhase;
00068   };
00069 
00070   // Private data:
00071   TFile*   fFile;
00072   TNtuple* fTree;
00073   TRandom* fRandom;
00074   TRandom* fParameterChooser;
00075 
00076 
00077   BlindingFunction fBlindingFunction;
00078 
00079 };
00080 #endif // BLINDER_H
00081 

Generated on Mon Feb 15 11:06:26 2010 for loon by  doxygen 1.3.9.1