CMS 3D CMS Logo

PixelThresholdClusterizer.h

Go to the documentation of this file.
00001 #ifndef RecoLocalTracker_SiPixelClusterizer_PixelThresholdClusterizer_H
00002 #define RecoLocalTracker_SiPixelClusterizer_PixelThresholdClusterizer_H
00003 
00004 //-----------------------------------------------------------------------
00039 //-----------------------------------------------------------------------
00040 
00041 // Base class, defines SiPixelDigi and SiPixelCluster.  The latter includes
00042 // Pixel, PixelPos and Shift as inner classes.
00043 //
00044 #include "DataFormats/Common/interface/DetSetVector.h"
00045 #include "RecoLocalTracker/SiPixelClusterizer/interface/PixelClusterizerBase.h"
00046 
00047 // The private pixel buffer
00048 #include "RecoLocalTracker/SiPixelClusterizer/interface/SiPixelArrayBuffer.h"
00049 
00050 // Parameter Set:
00051 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00052 
00053 // TimeMe class:
00054 //#include "Utilities/Timing/interface/TimingReport.h"
00055 
00056 #include <vector>
00057 
00058 
00059 class PixelThresholdClusterizer : public PixelClusterizerBase {
00060  public:
00061 
00062   PixelThresholdClusterizer(edm::ParameterSet const& conf);
00063   ~PixelThresholdClusterizer();
00064 
00065   // Full I/O in DetSet
00066   void clusterizeDetUnit( const edm::DetSet<PixelDigi> & input, 
00067                                   const PixelGeomDetUnit * pixDet,
00068                                   const std::vector<short>& badChannels,
00069                                   edmNew::DetSetVector<SiPixelCluster>::FastFiller& output);
00070 
00071   
00072  private:
00073 
00074   edm::ParameterSet conf_;
00075 
00077   SiPixelArrayBuffer               theBuffer;         // internal nrow * ncol matrix
00078   bool                             bufferAlreadySet;  // status of the buffer array
00079   std::vector<SiPixelCluster::PixelPos>  theSeeds;          // cached seed pixels
00080   std::vector<SiPixelCluster>            theClusters;       // resulting clusters  
00081   
00083   float thePixelThresholdInNoiseUnits;    // Pixel threshold in units of noise
00084   float theSeedThresholdInNoiseUnits;     // Pixel cluster seed in units of noise
00085   float theClusterThresholdInNoiseUnits;  // Cluster threshold in units of noise
00086 
00087   int   thePixelThreshold;  // Pixel threshold in electrons
00088   int   theSeedThreshold;   // Seed threshold in electrons 
00089   float theClusterThreshold;  // Cluster threshold in electrons
00090   int   theConversionFactor;  // adc to electron conversion factor
00091   int   theOffset;            // adc to electron conversion offset
00092 
00094   int  theNumOfRows;
00095   int  theNumOfCols;
00096   uint32_t detid_;
00097 
00098   bool doMissCalibrate; // Use calibration or not
00099 
00101   bool setup(const PixelGeomDetUnit * pixDet);
00102   void copy_to_buffer( DigiIterator begin, DigiIterator end );   
00103   void clear_buffer( DigiIterator begin, DigiIterator end );   
00104   SiPixelCluster make_cluster( const SiPixelCluster::PixelPos& pix );
00105   // Calibrate the ADC charge to electrons 
00106   int calibrate(int adc, int col, int row);
00107 
00108 /*   void initTiming(); */
00109 /*   TimingReport::Item * theSetupTimer; */
00110 /*   TimingReport::Item * theClustersTimer; */
00111 /*   TimingReport::Item * theClusterizeTimer; */
00112 /*   TimingReport::Item * theRecHitTimer; */
00113 /*   TimingReport::Item * theCopyTimer; */
00114 /*   TimingReport::Item * theClearTimer; */
00115 /*   TimingReport::Item * theMakeClustTimer; */
00116 /*   TimingReport::Item * theCacheGetTimer; */
00117 /*   TimingReport::Item * theCachePutTimer; */
00118 
00119 };
00120 
00121 #endif

Generated on Tue Jun 9 17:43:56 2009 for CMSSW by  doxygen 1.5.4