CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes
HitPairGeneratorFromLayerPairForPhotonConversion Class Reference

#include <HitPairGeneratorFromLayerPairForPhotonConversion.h>

Inheritance diagram for HitPairGeneratorFromLayerPairForPhotonConversion:
HitPairGenerator OrderedHitsGenerator

Public Types

typedef
SeedingLayerSetsHits::SeedingLayer 
Layer
 
typedef
CombinedHitPairGenerator::LayerCacheType 
LayerCacheType
 
typedef
SeedingLayerSetsHits::SeedingLayerSet 
Layers
 

Public Member Functions

bool checkBoundaries (const DetLayer &layer, const ConversionRegion &convRegion, float maxSearchR, float maxSearchZ)
 
bool checkRZCompatibilityWithSeedTrack (const RecHitsSortedInPhi::Hit &hit, const DetLayer &layer, const ConversionRegion &convRegion)
 
virtual
HitPairGeneratorFromLayerPairForPhotonConversion
clone () const
 
float getLayerRadius (const DetLayer &layer)
 
float getLayerZ (const DetLayer &layer)
 
bool getPhiRange (float &Phimin, float &Phimax, const DetLayer &layer, const ConversionRegion &convRegion, const edm::EventSetup &es)
 
bool getPhiRange (float &Phimin, float &Phimax, const float &layerR, const ConversionRegion &convRegion, const edm::EventSetup &es)
 
 HitPairGeneratorFromLayerPairForPhotonConversion (unsigned int inner, unsigned int outer, LayerCacheType *layerCache, unsigned int nSize=30000, unsigned int max=0)
 
void hitPairs (const ConversionRegion &convRegion, const TrackingRegion &reg, OrderedHitPairs &prs, const edm::Event &ev, const edm::EventSetup &es)
 
virtual void hitPairs (const TrackingRegion &reg, OrderedHitPairs &prs, const edm::Event &ev, const edm::EventSetup &es)
 
Layer innerLayer () const
 
Layer outerLayer () const
 
void setSeedingLayers (Layers layers) override
 
virtual ~HitPairGeneratorFromLayerPairForPhotonConversion ()
 
- Public Member Functions inherited from HitPairGenerator
virtual void clear ()
 
virtual HitDoublets doublets (const TrackingRegion &reg, const edm::Event &ev, const edm::EventSetup &es)
 
 HitPairGenerator (unsigned int size=7500)
 
virtual void hitPairs (const TrackingRegion &reg, OrderedHitPairs &prs, const edm::EventSetup &es)
 
virtual const OrderedHitPairsrun (const TrackingRegion &region, const edm::Event &ev, const edm::EventSetup &es)
 
virtual ~HitPairGenerator ()
 
- Public Member Functions inherited from OrderedHitsGenerator
 OrderedHitsGenerator ()
 
virtual ~OrderedHitsGenerator ()
 

Private Member Functions

double getCot (double dz, double dr)
 

Private Attributes

std::stringstream * ss
 
const unsigned int theInnerLayer
 
LayerCacheTypetheLayerCache
 
const unsigned int theOuterLayer
 
Layers theSeedingLayers
 

Additional Inherited Members

- Public Attributes inherited from OrderedHitsGenerator
unsigned int theMaxElement
 

Detailed Description

Definition at line 13 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

Member Typedef Documentation

Constructor & Destructor Documentation

HitPairGeneratorFromLayerPairForPhotonConversion::HitPairGeneratorFromLayerPairForPhotonConversion ( unsigned int  inner,
unsigned int  outer,
LayerCacheType layerCache,
unsigned int  nSize = 30000,
unsigned int  max = 0 
)
virtual HitPairGeneratorFromLayerPairForPhotonConversion::~HitPairGeneratorFromLayerPairForPhotonConversion ( )
inlinevirtual

Definition at line 27 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

27 { }

Member Function Documentation

bool HitPairGeneratorFromLayerPairForPhotonConversion::checkBoundaries ( const DetLayer layer,
const ConversionRegion convRegion,
float  maxSearchR,
float  maxSearchZ 
)

Definition at line 220 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References GeomDetEnumerators::barrel, ConversionRegion::convPoint(), gather_cfg::cout, GeomDetEnumerators::endcap, getLayerRadius(), getLayerZ(), DetLayer::location(), PV3DBase< T, PVType, FrameType >::perp(), dttmaxenums::R, Gflash::Z, and PV3DBase< T, PVType, FrameType >::z().

Referenced by hitPairs().

220  {
221 
222  if(layer.location() == GeomDetEnumerators::barrel){
223 
224  float minZEndCap=130;
225  if(fabs(convRegion.convPoint().z()) > minZEndCap){
226 #ifdef mydebug_Seed
227  (*ss) << "\tthe conversion seems to be in the endcap. Zconv " << convRegion.convPoint().z() << std::endl;
228  std::cout << (*ss).str();
229 #endif
230  return false;
231  }
232 
233  float R=getLayerRadius(layer);
234 
235  if(convRegion.convPoint().perp()>R){
236 #ifdef mydebug_Seed
237  (*ss) << "\tthis layer is before the conversion : R layer " << R << " [ Rconv " << convRegion.convPoint().perp() << " Zconv " << convRegion.convPoint().z()<< std::endl;
238  std::cout << (*ss).str();
239 #endif
240  return false;
241  }
242 
243  if(R - convRegion.convPoint().perp() > maxSearchR ){
244 #ifdef mydebug_Seed
245  (*ss) << "\tthis layer is far from the conversion more than cut " << maxSearchR << " cm. R layer " << R << " [ Rconv " << convRegion.convPoint().perp() << " Zconv " << convRegion.convPoint().z()<< std::endl;
246  std::cout << (*ss).str();
247 #endif
248  return false;
249  }
250 
251  }else if (layer.location() == GeomDetEnumerators::endcap){
252 
253  float Z=getLayerZ(layer);
254  if(
255  (convRegion.convPoint().z()>0 && convRegion.convPoint().z()>Z)
256  ||
257  (convRegion.convPoint().z()<0 && convRegion.convPoint().z()<Z)
258  ) {
259 #ifdef mydebug_Seed
260  (*ss) << "\tthis layer is before the conversion : Z layer " << Z << " [ Rconv " << convRegion.convPoint().perp()<< " Zconv " << convRegion.convPoint().z() << std::endl;
261  std::cout << (*ss).str();
262 #endif
263  return false;
264  }
265 
266 
267  if(fabs(Z - convRegion.convPoint().z()) > maxSearchZ ){
268 #ifdef mydebug_Seed
269  (*ss) << "\tthis layer is far from the conversion more than cut " << maxSearchZ << " cm. Z layer " << Z << " [ Rconv " << convRegion.convPoint().perp()<< " Zconv " << convRegion.convPoint().z() << std::endl;
270  std::cout << (*ss).str();
271 #endif
272  return false;
273  }
274 
275  }
276  return true;
277 }
const double Z[kNumberCalorimeter]
T perp() const
Definition: PV3DBase.h:72
virtual Location location() const =0
Which part of the detector (barrel, endcap)
GlobalPoint convPoint() const
T z() const
Definition: PV3DBase.h:64
tuple cout
Definition: gather_cfg.py:121
bool HitPairGeneratorFromLayerPairForPhotonConversion::checkRZCompatibilityWithSeedTrack ( const RecHitsSortedInPhi::Hit hit,
const DetLayer layer,
const ConversionRegion convRegion 
)

Definition at line 322 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References GeomDetEnumerators::barrel, ConversionRegion::convPoint(), ConversionRegion::cotTheta(), ConversionRegion::errTheta(), f, getCot(), PixelRecoRange< T >::intersection(), DetLayer::location(), PixelRecoRange< T >::min(), nSigmaRZ, ConversionRegion::pvtxPoint(), funct::sqr(), mathSSE::sqrt(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by hitPairs().

322  {
323  static const float nSigmaRZ = std::sqrt(12.f);
324  Range hitCotTheta;
325 
326  double sigmaCotTheta = convRegion.errTheta() * (1+convRegion.cotTheta()*convRegion.cotTheta()); //Error Propagation from sigma theta.
327  Range allowedCotTheta(convRegion.cotTheta()-nSigmaRZ*sigmaCotTheta,convRegion.cotTheta()+nSigmaRZ*sigmaCotTheta);
328 
329  double dz = hit->globalPosition().z()-convRegion.pvtxPoint().z();
330  double r_reduced = std::sqrt( sqr(hit->globalPosition().x()-convRegion.pvtxPoint().x())+sqr(hit->globalPosition().y()-convRegion.pvtxPoint().y()));
331 
332  if (layer.location() == GeomDetEnumerators::barrel){
333  float zErr = nSigmaRZ * hit->errorGlobalZ();
334  hitCotTheta = Range(getCot(dz-zErr,r_reduced),getCot(dz+zErr,r_reduced));
335  }else{
336  float rErr = nSigmaRZ * hit->errorGlobalR();
337  if(dz>0)
338  hitCotTheta = Range(getCot(dz,r_reduced+rErr),getCot(dz,r_reduced-rErr));
339  else
340  hitCotTheta = Range(getCot(dz,r_reduced-rErr), getCot(dz,r_reduced+rErr));
341  }
342 
343  Range crossRange = allowedCotTheta.intersection(hitCotTheta);
344 
345 #ifdef mydebug_Seed
346  (*ss)
347  << "\n\t\t cotTheta allowed Range " << allowedCotTheta.min() << " \t, " << allowedCotTheta.max()
348  << "\n\t\t hitCotTheta Range " << hitCotTheta.min() << " \t, " << hitCotTheta.max()
349  << "\n\t\t Cross Range " << crossRange.min() << " \t, " << crossRange.max()
350  << "\n\t\t the seed track has origin " << convRegion.convPoint() << " \t cotTheta " << convRegion.cotTheta()
351  << std::endl;
352 #endif
353 
354  return crossRange.empty();
355 }
float cotTheta() const
virtual Location location() const =0
Which part of the detector (barrel, endcap)
GlobalPoint pvtxPoint() const
T y() const
Definition: PV3DBase.h:63
GlobalPoint convPoint() const
T min() const
constexpr double nSigmaRZ
T sqrt(T t)
Definition: SSEVec.h:48
T z() const
Definition: PV3DBase.h:64
double f[11][100]
PixelRecoRange< float > Range
double errTheta() const
PixelRecoRange< T > intersection(const PixelRecoRange< T > &r) const
Square< F >::type sqr(const F &f)
Definition: Square.h:13
T x() const
Definition: PV3DBase.h:62
virtual HitPairGeneratorFromLayerPairForPhotonConversion* HitPairGeneratorFromLayerPairForPhotonConversion::clone ( void  ) const
inlinevirtual

Implements HitPairGenerator.

Definition at line 37 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

References HitPairGeneratorFromLayerPairForPhotonConversion().

37  {
39  }
HitPairGeneratorFromLayerPairForPhotonConversion(unsigned int inner, unsigned int outer, LayerCacheType *layerCache, unsigned int nSize=30000, unsigned int max=0)
double HitPairGeneratorFromLayerPairForPhotonConversion::getCot ( double  dz,
double  dr 
)
private

Definition at line 359 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References funct::abs(), alignCSCRings::e, and f.

Referenced by checkRZCompatibilityWithSeedTrack().

359  {
360  if ( std::abs(dr) > 1.e-4f ) return dz/dr;
361  else
362  if(dz>0) return 99999.f;
363  else return -99999.f;
364 }
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
double f[11][100]
float HitPairGeneratorFromLayerPairForPhotonConversion::getLayerRadius ( const DetLayer layer)

Definition at line 195 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References GeomDetEnumerators::barrel, Surface::bounds(), DetLayer::location(), BarrelDetLayer::specificSurface(), GeometricSearchDet::surface(), and Bounds::thickness().

Referenced by checkBoundaries(), and getPhiRange().

195  {
196  if (layer.location() == GeomDetEnumerators::barrel){
197  const BarrelDetLayer& bl = static_cast<const BarrelDetLayer&>(layer);
198  float rLayer = bl.specificSurface().radius();
199 
200  // the maximal delta phi will be for the innermost hits
201  float theThickness = layer.surface().bounds().thickness();
202  return rLayer + 0.5f*theThickness;
203  }
204 
205  //Fixme
206  return 0;
207 }
virtual const BoundSurface & surface() const =0
The surface of the GeometricSearchDet.
virtual Location location() const =0
Which part of the detector (barrel, endcap)
const Bounds & bounds() const
Definition: Surface.h:128
virtual float thickness() const =0
virtual const BoundCylinder & specificSurface() const GCC11_FINAL
Extension of the interface.
float HitPairGeneratorFromLayerPairForPhotonConversion::getLayerZ ( const DetLayer layer)

Definition at line 209 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References Surface::bounds(), GeomDetEnumerators::endcap, DetLayer::location(), GeometricSearchDet::position(), GeometricSearchDet::surface(), Bounds::thickness(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by checkBoundaries(), and getPhiRange().

209  {
210  if (layer.location() == GeomDetEnumerators::endcap){
211  float layerZ = layer.position().z();
212  float theThickness = layer.surface().bounds().thickness();
213  float layerZmax = layerZ > 0 ? layerZ+0.5f*theThickness: layerZ-0.5f*theThickness;
214  return layerZmax;
215  }else{
216  //Fixme
217  return 0;
218  }
219 }
virtual const BoundSurface & surface() const =0
The surface of the GeometricSearchDet.
virtual Location location() const =0
Which part of the detector (barrel, endcap)
const Bounds & bounds() const
Definition: Surface.h:128
virtual float thickness() const =0
T z() const
Definition: PV3DBase.h:64
virtual const Surface::PositionType & position() const
Returns position of the surface.
bool HitPairGeneratorFromLayerPairForPhotonConversion::getPhiRange ( float &  Phimin,
float &  Phimax,
const DetLayer layer,
const ConversionRegion convRegion,
const edm::EventSetup es 
)

Definition at line 279 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References GeomDetEnumerators::barrel, ConversionRegion::cotTheta(), GeomDetEnumerators::endcap, getLayerRadius(), getLayerZ(), DetLayer::location(), dttmaxenums::R, and Gflash::Z.

Referenced by hitPairs().

279  {
280  if(layer.location() == GeomDetEnumerators::barrel){
281  return getPhiRange(Phimin,Phimax,getLayerRadius(layer),convRegion,es);
282  }else if (layer.location() == GeomDetEnumerators::endcap){
283  float Z=getLayerZ(layer);
284  float R=Z/convRegion.cotTheta();
285  return getPhiRange(Phimin,Phimax,R,convRegion,es); //FIXME
286  }
287  return false;
288 }
const double Z[kNumberCalorimeter]
float cotTheta() const
virtual Location location() const =0
Which part of the detector (barrel, endcap)
bool getPhiRange(float &Phimin, float &Phimax, const DetLayer &layer, const ConversionRegion &convRegion, const edm::EventSetup &es)
bool HitPairGeneratorFromLayerPairForPhotonConversion::getPhiRange ( float &  Phimin,
float &  Phimax,
const float &  layerR,
const ConversionRegion convRegion,
const edm::EventSetup es 
)

Definition at line 290 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References PixelRecoUtilities::bendingRadius(), ConversionRegion::charge(), ConversionRegion::convPoint(), reco::deltaPhi(), PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), RecoTau_DiTaus_pt_20-420_cfg::Phimin, ptmin, funct::sqr(), and mathSSE::sqrt().

290  {
291  Phimin = reco::deltaPhi(convRegion.convPoint().phi(),0.);
292 
293  float dphi;
294  float ptmin=0.1;
295  float DeltaL=layerR-convRegion.convPoint().perp();
296 
297  if(DeltaL<0){
298  Phimin=0;
299  Phimax=0;
300  return false;
301  }
302 
303  float theRCurvatureMin = PixelRecoUtilities::bendingRadius(ptmin,es);
304 
305  if(theRCurvatureMin<DeltaL)
306  dphi = atan(DeltaL/layerR);
307  else
308  dphi = atan(theRCurvatureMin/layerR * ( 1 - sqrt(1-sqr(DeltaL/theRCurvatureMin)) ) );
309 
310  if(convRegion.charge()>0){
311  Phimax=Phimin;
312  Phimin=Phimax-dphi;
313  }else{
314  Phimax=Phimin+dphi;
315  }
316 
317  //std::cout << dphi << " " << Phimin << " " << Phimax << " " << layerR << " " << DeltaL << " " << convRegion.convPoint().phi() << " " << convRegion.convPoint().perp()<< std::endl;
318  return true;
319 }
T perp() const
Definition: PV3DBase.h:72
int charge() const
Geom::Phi< T > phi() const
Definition: PV3DBase.h:69
GlobalPoint convPoint() const
T sqrt(T t)
Definition: SSEVec.h:48
double deltaPhi(double phi1, double phi2)
Definition: deltaPhi.h:12
T bendingRadius(T pt, const edm::EventSetup &iSetup)
double ptmin
Definition: HydjetWrapper.h:85
Square< F >::type sqr(const F &f)
Definition: Square.h:13
void HitPairGeneratorFromLayerPairForPhotonConversion::hitPairs ( const ConversionRegion convRegion,
const TrackingRegion reg,
OrderedHitPairs prs,
const edm::Event ev,
const edm::EventSetup es 
)

Definition at line 48 of file HitPairGeneratorFromLayerPairForPhotonConversion.cc.

References Reference_intrackfit_cff::barrel, checkBoundaries(), TrackingRegion::checkRZ(), checkRZCompatibilityWithSeedTrack(), ConversionRegion::convPoint(), ConversionRegion::cotTheta(), gather_cfg::cout, SeedingLayerSetsHits::SeedingLayer::detLayer(), RecHitsSortedInPhi::empty(), f, getPhiRange(), RecHitsSortedInPhi::hits(), innerLayer(), PixelRecoRange< T >::intersection(), DetLayer::location(), PixelRecoRange< T >::min(), SeedingLayerSetsHits::SeedingLayer::name(), nSigmaRZ, TrackingRegion::origin(), outerLayer(), PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), HitRZCompatibility::range(), OrderedHitPairs::size(), funct::sqr(), mathSSE::sqrt(), ss, theLayerCache, OrderedHitsGenerator::theMaxElement, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

51 {
52 
53  ss->str("");
54 
55  typedef OrderedHitPair::InnerRecHit InnerHit;
56  typedef OrderedHitPair::OuterRecHit OuterHit;
58 
59  Layer innerLayerObj = innerLayer();
60  Layer outerLayerObj = outerLayer();
61 
62 #ifdef mydebug_Seed
63  (*ss) << "In " << innerLayerObj.name() << " Out " << outerLayerObj.name() << std::endl;
64 #endif
65 
66  if(!checkBoundaries(*innerLayerObj.detLayer(),convRegion,40.,60.)) return; //FIXME, the maxSearchR(Z) are not optimized
67  if(!checkBoundaries(*outerLayerObj.detLayer(),convRegion,50.,60.)) return; //FIXME, the maxSearchR(Z) are not optimized
68 
69  /*get hit sorted in phi for each layer: NB: doesn't apply any region cut*/
70  const RecHitsSortedInPhi & innerHitsMap = theLayerCache(innerLayerObj, region, event, es);
71  if (innerHitsMap.empty()) return;
72 
73  const RecHitsSortedInPhi& outerHitsMap = theLayerCache(outerLayerObj, region, event, es);
74  if (outerHitsMap.empty()) return;
75  /*----------------*/
76 
77  /*This object will check the compatibility of the his in phi among the two layers. */
78  //InnerDeltaPhi deltaPhi(innerLayerObj.detLayer(), region, es);
79 
80  static const float nSigmaRZ = std::sqrt(12.f);
81  // static const float nSigmaPhi = 3.f;
82  vector<RecHitsSortedInPhi::Hit> innerHits, outerHits;
83  float outerPhimin, outerPhimax;
84  float innerPhimin, innerPhimax;
85 
86  /*Getting only the Hits in the outer layer that are compatible with the conversion region*/
87  if(!getPhiRange(outerPhimin,outerPhimax,*outerLayerObj.detLayer(),convRegion,es)) return;
88  outerHitsMap.hits( outerPhimin, outerPhimax, outerHits);
89 
90 #ifdef mydebug_Seed
91  (*ss) << "\tophimin, ophimax " << outerPhimin << " " << outerPhimax << std::endl;
92 #endif
93 
94  /* loop on outer hits*/
95  for (vector<RecHitsSortedInPhi::Hit>::const_iterator oh = outerHits.begin(); oh!= outerHits.end(); ++oh) {
96  RecHitsSortedInPhi::Hit ohit = (*oh);
97 #ifdef mydebug_Seed
98  GlobalPoint oPos = ohit->globalPosition();
99 
100  (*ss) << "\toPos " << oPos << " r " << oPos.perp() << " phi " << oPos.phi() << " cotTheta " << oPos.z()/oPos.perp() << std::endl;
101 #endif
102 
103  /*Check the compatibility of the ohit with the eta of the seeding track*/
104  if(checkRZCompatibilityWithSeedTrack(ohit,*outerLayerObj.detLayer(),convRegion)) continue;
105 
106  /*
107  //Do I need this? it uses a compatibility that probably I wouldn't
108  //Removing for the time being
109 
110  PixelRecoRange<float> phiRange = deltaPhi( oPos.perp(), oPos.phi(), oPos.z(), nSigmaPhi*(ohit->errorGlobalRPhi()));
111  if (phiRange.empty()) continue;
112  */
113 
114  const HitRZCompatibility *checkRZ = region.checkRZ(innerLayerObj.detLayer(), ohit, es);
115  if(!checkRZ) {
116 #ifdef mydebug_Seed
117  (*ss) << "*******\nNo valid checkRZ\n*******" << std::endl;
118 #endif
119  continue;
120  }
121 
122  /*Get only the inner hits compatible with the conversion region*/
123  innerHits.clear();
124  if(!getPhiRange(innerPhimin,innerPhimax,*innerLayerObj.detLayer(),convRegion,es)) continue;
125  innerHitsMap.hits(innerPhimin, innerPhimax, innerHits);
126 
127 #ifdef mydebug_Seed
128  (*ss) << "\tiphimin, iphimax " << innerPhimin << " " << innerPhimax << std::endl;
129 #endif
130 
131  /*Loop on inner hits*/
132  for ( vector<RecHitsSortedInPhi::Hit>::const_iterator ih=innerHits.begin(), ieh = innerHits.end(); ih < ieh; ++ih) {
133  GlobalPoint innPos = (*ih)->globalPosition();
134 
135 
136 #ifdef mydebug_Seed
137  (*ss) << "\tinnPos " << innPos << " r " << innPos.perp() << " phi " << innPos.phi() << " cotTheta " << innPos.z()/innPos.perp() << std::endl;
138 #endif
139 
140  /*Check the compatibility of the ohit with the eta of the seeding track*/
141  if(checkRZCompatibilityWithSeedTrack(*ih,*innerLayerObj.detLayer(),convRegion)) continue;
142 
143  float r_reduced = std::sqrt( sqr(innPos.x()-region.origin().x())+sqr(innPos.y()-region.origin().y()));
144  Range allowed;
145  Range hitRZ;
146  if (innerLayerObj.detLayer()->location() == barrel) {
147  allowed = checkRZ->range(r_reduced);
148  float zErr = nSigmaRZ * (*ih)->errorGlobalZ();
149  hitRZ = Range(innPos.z()-zErr, innPos.z()+zErr);
150  } else {
151  allowed = checkRZ->range(innPos.z());
152  float rErr = nSigmaRZ * (*ih)->errorGlobalR();
153  hitRZ = Range(r_reduced-rErr, r_reduced+rErr);
154  }
155  Range crossRange = allowed.intersection(hitRZ);
156 
157 #ifdef mydebug_Seed
158  (*ss)
159  << "\n\t\t allowed Range " << allowed.min() << " \t, " << allowed.max()
160  << "\n\t\t hitRz Range " << hitRZ.min() << " \t, " << hitRZ.max()
161  << "\n\t\t Cross Range " << crossRange.min() << " \t, " << crossRange.max()
162  << "\n\t\t the seed track has origin " << convRegion.convPoint() << " \t cotTheta " << convRegion.cotTheta()
163  << std::endl;
164 #endif
165 
166  if (! crossRange.empty() ) {
167 #ifdef mydebug_Seed
168  (*ss)
169  << "\n\t\t !!!!ACCEPTED!!! \n\n";
170 #endif
171  if (theMaxElement!=0 && result.size() >= theMaxElement){
172  result.clear();
173 #ifdef mydebug_Seed
174  edm::LogError("TooManySeeds")<<"number of pairs exceed maximum, no pairs produced";
175 #endif
176  delete checkRZ;
177 
178 #ifdef mydebug_Seed
179  std::cout << (*ss).str();
180 #endif
181  return;
182  }
183  result.push_back( OrderedHitPair( *ih, ohit) );
184  }
185  }
186  delete checkRZ;
187  }
188 
189 #ifdef mydebug_Seed
190  std::cout << (*ss).str();
191 #endif
192 }
std::vector< Hit > hits(float phiMin, float phiMax) const
float cotTheta() const
bool checkRZCompatibilityWithSeedTrack(const RecHitsSortedInPhi::Hit &hit, const DetLayer &layer, const ConversionRegion &convRegion)
T perp() const
Definition: PV3DBase.h:72
virtual Range range(const float &rORz) const =0
Geom::Phi< T > phi() const
Definition: PV3DBase.h:69
T y() const
Definition: PV3DBase.h:63
GlobalPoint convPoint() const
T min() const
constexpr double nSigmaRZ
T sqrt(T t)
Definition: SSEVec.h:48
T z() const
Definition: PV3DBase.h:64
tuple result
Definition: query.py:137
bool getPhiRange(float &Phimin, float &Phimax, const DetLayer &layer, const ConversionRegion &convRegion, const edm::EventSetup &es)
double f[11][100]
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
PixelRecoRange< float > Range
bool checkBoundaries(const DetLayer &layer, const ConversionRegion &convRegion, float maxSearchR, float maxSearchZ)
PixelRecoRange< T > intersection(const PixelRecoRange< T > &r) const
Square< F >::type sqr(const F &f)
Definition: Square.h:13
TransientTrackingRecHit::ConstRecHitPointer Hit
tuple cout
Definition: gather_cfg.py:121
T x() const
Definition: PV3DBase.h:62
virtual void HitPairGeneratorFromLayerPairForPhotonConversion::hitPairs ( const TrackingRegion reg,
OrderedHitPairs prs,
const edm::Event ev,
const edm::EventSetup es 
)
inlinevirtual

Implements HitPairGenerator.

Definition at line 34 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

35  {};
Layer HitPairGeneratorFromLayerPairForPhotonConversion::innerLayer ( ) const
inline
Layer HitPairGeneratorFromLayerPairForPhotonConversion::outerLayer ( ) const
inline
void HitPairGeneratorFromLayerPairForPhotonConversion::setSeedingLayers ( Layers  layers)
inlineoverridevirtual

Implements HitPairGenerator.

Definition at line 29 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

References LayerTriplets::layers(), and theSeedingLayers.

std::vector< LayerSetAndLayers > layers(const SeedingLayerSetsHits &sets)
Definition: LayerTriplets.cc:4

Member Data Documentation

std::stringstream* HitPairGeneratorFromLayerPairForPhotonConversion::ss
private
const unsigned int HitPairGeneratorFromLayerPairForPhotonConversion::theInnerLayer
private

Definition at line 60 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

Referenced by innerLayer().

LayerCacheType& HitPairGeneratorFromLayerPairForPhotonConversion::theLayerCache
private

Definition at line 57 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

Referenced by hitPairs().

const unsigned int HitPairGeneratorFromLayerPairForPhotonConversion::theOuterLayer
private

Definition at line 59 of file HitPairGeneratorFromLayerPairForPhotonConversion.h.

Referenced by outerLayer().

Layers HitPairGeneratorFromLayerPairForPhotonConversion::theSeedingLayers
private