#include <StripCPEgeometric.h>
Definition at line 7 of file StripCPEgeometric.h.
StripCPEgeometric::StripCPEgeometric | ( | edm::ParameterSet & | conf, |
const MagneticField & | mag, | ||
const TrackerGeometry & | geom, | ||
const SiStripLorentzAngle & | LorentzAngle, | ||
const SiStripConfObject & | confObj, | ||
const SiStripLatency & | latency | ||
) | [inline] |
Definition at line 18 of file StripCPEgeometric.h.
: StripCPE(conf, mag, geom, LorentzAngle, confObj, latency ), tan_diffusion_angle(conf.getParameter<double>("TanDiffusionAngle")), thickness_rel_err2(pow(conf.getParameter<double>("ThicknessRelativeUncertainty"), 2)), noise_threshold(conf.getParameter<double>("NoiseThreshold")), maybe_noise_threshold(conf.getParameter<double>("MaybeNoiseThreshold")), scaling_squared(pow(conf.getParameter<double>("UncertaintyScaling"), 2)), minimum_uncertainty_squared(pow(conf.getParameter<double>("MinimumUncertainty"),2)) {}
bool StripCPEgeometric::ambiguousSize | ( | const WrappedCluster & | wc, |
const stats_t< float > & | proj | ||
) | const [inline, private] |
Definition at line 91 of file StripCPEgeometric.cc.
References maybe_noise_threshold, StripCPEgeometric::WrappedCluster::N, and StripCPEgeometric::WrappedCluster::smallerEdgeStrip().
Referenced by offset_from_firstStrip().
{ return proj() < wc.N-1 && wc.smallerEdgeStrip()()>0 && wc.smallerEdgeStrip().sigmaFrom(0) < maybe_noise_threshold; }
stats_t< float > StripCPEgeometric::geometric_position | ( | const WrappedCluster & | wc, |
const stats_t< float > & | proj | ||
) | const [private] |
Definition at line 61 of file StripCPEgeometric.cc.
References stats_t< T >::error2(), StripCPEgeometric::WrappedCluster::eta(), StripCPEgeometric::WrappedCluster::middle(), StripCPEgeometric::WrappedCluster::N, funct::pow(), scaling_squared, and ExpressReco_HICollisions_FallBack::x.
Referenced by offset_from_firstStrip().
{ const stats_t<float> x = wc.middle() + 0.5 * proj * wc.eta(); return wc.N==1 ? stats_t<float>( x(), pow( 1-0.82*proj(), 2 ) / 12 ) : stats_t<float>( x(), scaling_squared * x.error2() ) ; }
StripClusterParameterEstimator::LocalValues StripCPEgeometric::localParameters | ( | const SiStripCluster & | cluster, |
const LocalTrajectoryParameters & | ltp | ||
) | const |
Definition at line 12 of file StripCPEgeometric.cc.
References SiStripCluster::amplitudes(), StripCPE::Param::coveredStrips(), StripCPE::Param::drift, SiStripCluster::firstStrip(), SiStripCluster::geographicalId(), StripTopology::localError(), StripTopology::localPitch(), StripTopology::localPosition(), PV3DBase< T, PVType, FrameType >::mag(), max(), StripCPE::Param::maxLength, minimum_uncertainty_squared, StripCPE::Param::moduleGeom, LocalTrajectoryParameters::momentum(), offset_from_firstStrip(), L1TEmulatorMonitor_cff::p, StripCPE::param(), StripCPE::Param::pitch_rel_err2, pos, LocalTrajectoryParameters::position(), StripCPE::shift, strip(), tan_diffusion_angle, StripCPE::Param::thickness, thickness_rel_err2, StripCPE::Param::topology, ExpressReco_HICollisions_FallBack::track, reco::InverseCrosstalkMatrix::unfold(), LocalTrajectoryParameters::vector(), StripCPE::xtalk1, and PV3DBase< T, PVType, FrameType >::z().
Referenced by localParameters().
{ StripCPE::Param const& p = param(cluster.geographicalId()); const LocalPoint& pos = ltp.position(); LocalVector track = ltp.momentum(); track *= (track.z()<0) ? fabs(p.thickness/track.z()) : (track.z()>0) ? -fabs(p.thickness/track.z()) : p.maxLength/track.mag() ; const float fullProjection = p.coveredStrips( track+p.drift, pos ); stats_t<float> projection; { const float absProj = fabs( fullProjection ); const float minProj = 2*p.thickness*tan_diffusion_angle/p.topology->localPitch(pos); const float projection_rel_err2 = thickness_rel_err2 + p.pitch_rel_err2; projection = stats_t<float>::from_relative_uncertainty2( std::max(absProj, minProj), projection_rel_err2); } const std::vector<stats_t<float> > Q = reco::InverseCrosstalkMatrix::unfold( cluster.amplitudes(), xtalk1[p.moduleGeom] ); const stats_t<float> strip = cluster.firstStrip() + offset_from_firstStrip( Q, projection ); const float corrected = strip() - 0.5*(1-shift[p.moduleGeom]) * fullProjection + 0.5*p.coveredStrips(track, ltp.position()); const float error2 = std::max( strip.error2(), minimum_uncertainty_squared ); return std::make_pair( p.topology->localPosition( corrected, ltp.vector()), p.topology->localError( corrected, error2, ltp.vector())); }
StripClusterParameterEstimator::LocalValues StripCPEgeometric::localParameters | ( | const SiStripCluster & | cluster, |
const GeomDetUnit & | det, | ||
const LocalTrajectoryParameters & | ltp | ||
) | const [virtual] |
Reimplemented from ClusterParameterEstimator< SiStripCluster >.
Definition at line 7 of file StripCPEgeometric.cc.
References localParameters().
{ return localParameters(cluster,ltp); }
stats_t< float > StripCPEgeometric::offset_from_firstStrip | ( | const std::vector< stats_t< float > > & | Q, |
const stats_t< float > & | proj | ||
) | const [private] |
Definition at line 42 of file StripCPEgeometric.cc.
References StripCPEgeometric::WrappedCluster::addSuppressedEdgeStrip(), ambiguousSize(), StripCPEgeometric::WrappedCluster::centroid(), StripCPEgeometric::WrappedCluster::deformed(), StripCPEgeometric::WrappedCluster::dropSmallerEdgeStrip(), stats_t< T >::error2(), geometric_position(), max(), StripCPEgeometric::WrappedCluster::maxProjection(), StripCPEgeometric::WrappedCluster::middle(), StripCPEgeometric::WrappedCluster::N, funct::pow(), useNMinusOne(), and useNPlusOne().
Referenced by localParameters().
{ WrappedCluster wc(Q); if( useNPlusOne( wc, proj)) wc.addSuppressedEdgeStrip(); else while( useNMinusOne( wc, proj)) wc.dropSmallerEdgeStrip(); if( proj() < wc.N-2 ) return stats_t<float>( wc.middle(), pow(wc.N-proj(),2) / 12.); if( wc.deformed() ) return stats_t<float>( wc.centroid()(), 1 / 12.); if( proj > wc.maxProjection() ) return stats_t<float>( wc.centroid()(), 1 / 12.); if( ambiguousSize( wc, proj) ) { const stats_t<float> probably = geometric_position( wc, proj); wc.dropSmallerEdgeStrip(); const stats_t<float> maybe = geometric_position( wc, proj); return stats_t<float>( probably(), std::max( probably.error2(), float(maybe.error2() + pow( probably()-maybe() ,2)/12 )) ); } return geometric_position( wc, proj); }
bool StripCPEgeometric::useNMinusOne | ( | const WrappedCluster & | wc, |
const stats_t< float > & | proj | ||
) | const [inline, private] |
Definition at line 75 of file StripCPEgeometric.cc.
References StripCPEgeometric::WrappedCluster::dropSmallerEdgeStrip(), StripCPEgeometric::WrappedCluster::eta(), StripCPEgeometric::WrappedCluster::maxProjection(), StripCPEgeometric::WrappedCluster::N, noise_threshold, StripCPEgeometric::WrappedCluster::sign(), and StripCPEgeometric::WrappedCluster::smallerEdgeStrip().
Referenced by offset_from_firstStrip().
{ if( proj() > wc.N-1) return false; if( wc.smallerEdgeStrip() < 0 ) return true; if( proj() < wc.N-3) return false; if( proj() < wc.N-2) return true; if( wc.eta().sigmaFrom(0) < 3) return false; WrappedCluster wcTest(wc); wcTest.dropSmallerEdgeStrip(); if( proj >= wcTest.maxProjection() ) return false; if( wc.sign()*wc.eta()() > 1./(wc.N-1) ) return true; return wc.smallerEdgeStrip().sigmaFrom(0) < noise_threshold; }
bool StripCPEgeometric::useNPlusOne | ( | const WrappedCluster & | wc, |
const stats_t< float > & | proj | ||
) | const [inline, private] |
Definition at line 70 of file StripCPEgeometric.cc.
References StripCPEgeometric::WrappedCluster::maxProjection(), and StripCPEgeometric::WrappedCluster::N.
Referenced by offset_from_firstStrip().
{ return wc.maxProjection() < proj && proj() < wc.N+1 ; }
const float StripCPEgeometric::maybe_noise_threshold [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by ambiguousSize().
const float StripCPEgeometric::minimum_uncertainty_squared [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by localParameters().
const float StripCPEgeometric::noise_threshold [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by useNMinusOne().
const float StripCPEgeometric::scaling_squared [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by geometric_position().
const float StripCPEgeometric::tan_diffusion_angle [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by localParameters().
const float StripCPEgeometric::thickness_rel_err2 [private] |
Definition at line 36 of file StripCPEgeometric.h.
Referenced by localParameters().