CMS 3D CMS Logo

Exercises2.h

Go to the documentation of this file.
00001 #ifndef EXERCISES2_H_
00002 #define EXERCISES2_H_
00003 
00004 #include "RecoParticleFlow/PFClusterTools/interface/Calibratable.h"
00005 #include "RecoParticleFlow/PFClusterTools/interface/Calibrator.h"
00006 #include "RecoParticleFlow/PFClusterTools/interface/CalibrationTarget.h"
00007 #include "RecoParticleFlow/PFClusterTools/interface/DetectorElement.h"
00008 #include "RecoParticleFlow/PFClusterTools/interface/CalibrationProvenance.h"
00009 #include "RecoParticleFlow/PFClusterTools/interface/SpaceManager.h"
00010 #include "RecoParticleFlow/PFClusterTools/interface/IO.h"
00011 #include "RecoParticleFlow/PFClusterTools/interface/PFClusterCalibration.h"
00012 
00013 #include <string>
00014 #include <vector>
00015 #include <TFile.h>
00016 #include <TTree.h>
00017 #include <fstream>
00018 
00019 namespace pftools {
00020 class Exercises2 {
00021 public:
00022                 
00023         Exercises2(IO* options);
00024         
00025         virtual ~Exercises2();
00026 
00027         void calibrateCalibratables(const std::string& sourcefile,
00028                         const std::string& exercisefile);
00029 
00030         //void gaussianFits(TFile& exercisefile, std::vector<Calibratable>& calibs);
00031 
00032         void evaluateCalibrator(SpaceManagerPtr s, CalibratorPtr c, TTree& tree,
00033                         Calibratable* calibrated, DetectorElementPtr ecal,
00034                         DetectorElementPtr hcal, DetectorElementPtr offset, CalibrationProvenance cp, CalibrationProvenance cpCorr = NONE);
00035 
00036         
00037         void evaluateSpaceManager(SpaceManagerPtr s, std::vector<DetectorElementPtr> detEls);
00038 
00039         void determineCorrection(TFile& f, TTree& tree, TF1*& f1, TF1*& f2);
00040         
00041         void setTarget(CalibrationTarget t) {
00042                 target_ = t;
00043         }
00044         
00045         
00046         void getCalibrations(SpaceManagerPtr s);
00047 
00048 private:
00049         
00050         Exercises2(const Exercises2&);
00051         void operator=(const Exercises2&);
00052 //      double lowE_, highE_, lowEta_, highEta_, lowPhi_, highPhi_;
00053 //      unsigned divE_, divEta_, divPhi_;
00054         bool withOffset_;
00055         CalibrationTarget target_;
00056         unsigned threshold_;
00057         std::vector<DetectorElementPtr> elements_;
00058         IO* options_;
00059         std::ofstream calibResultsFile_;
00060         unsigned debug_;
00061         PFClusterCalibration clusterCalibration_;
00062 
00063 };
00064 }
00065 
00066 #endif /*EXERCISES2_H_*/

Generated on Tue Jun 9 17:44:41 2009 for CMSSW by  doxygen 1.5.4