CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiPixelTemplateSplit.h
Go to the documentation of this file.
1 //
2 // SiPixelTemplateSplit.cc (Version 1.05)
3 //
4 // Procedure to fit two templates (same angle hypotheses) to a single cluster
5 // Return two x- and two y-coordinates for the cluster
6 //
7 // Created by Morris Swartz on 04/10/08.
8 // Copyright 2008 __TheJohnsHopkinsUniversity__. All rights reserved.
9 //
10 // Incorporate "cluster repair" to handle dead pixels
11 // Take truncation size from new pixmax information
12 // Change to allow template sizes to be changed at compile time
13 // Move interpolation range error to LogDebug
14 // Add qbin = 5 and change 1-pixel probability to use new template info
15 // Add floor for probabilities (no exact zeros)
16 //
17 
18 #ifndef SI_PIXEL_TEMPLATE_STANDALONE
20 #else
21 #include "SiPixelTemplate.h"
22 #endif
23 
24 //#define TYSIZE 21
25 //#define BYSIZE TYSIZE+4
26 //#define BHY 12 // = BYSIZE/2
27 //#define BYM1 TYSIZE+3
28 //#define BYM2 TYSIZE+2
29 //#define BYM3 TYSIZE+1
30 //#define TXSIZE 7
31 //#define BXSIZE TXSIZE+4
32 //#define BHX 5 // = BXSIZE/2
33 //#define BXM1 TXSIZE+3
34 //#define BXM2 TXSIZE+2
35 //#define BXM3 TXSIZE+1
36 
37 #include <vector>
38 #include "boost/multi_array.hpp"
39 
40 
41 namespace SiPixelTemplateReco
42  {
43 
44  typedef boost::multi_array<float, 2> array_2d;
45  typedef boost::multi_array<float, 3> array_3d;
46 
47  int PixelTempSplit(int id, bool fpix, float cotalpha, float cotbeta, array_2d cluster,
48  std::vector<bool> ydouble, std::vector<bool> xdouble,
49  SiPixelTemplate& templ,
50  float& yrec1, float& yrec2, float& sigmay, float& proby,
51  float& xrec1, float& xrec2, float& sigmax, float& probx, int& qbin, bool deadpix, std::vector<std::pair<int, int> > zeropix);
52 
53  int PixelTempSplit(int id, bool fpix, float cotalpha, float cotbeta, array_2d cluster,
54  std::vector<bool> ydouble, std::vector<bool> xdouble,
55  SiPixelTemplate& templ,
56  float& yrec1, float& yrec2, float& sigmay, float& proby,
57  float& xrec1, float& xrec2, float& sigmax, float& probx, int& qbin);
58 
59 }
60 
61 
boost::multi_array< float, 2 > array_2d
boost::multi_array< float, 3 > array_3d
int PixelTempSplit(int id, bool fpix, float cotalpha, float cotbeta, array_2d cluster, std::vector< bool > ydouble, std::vector< bool > xdouble, SiPixelTemplate &templ, float &yrec1, float &yrec2, float &sigmay, float &proby, float &xrec1, float &xrec2, float &sigmax, float &probx, int &qbin, bool deadpix, std::vector< std::pair< int, int > > zeropix)