 |
ATLAS Offline Software
|
#include <FPGATrackSimKeyLayerBinDesc.h>
|
| Gaudi::Property< double > | m_rin {this, "rin", {-1.0}, "Radius of inner layer for keylayer definition"} |
| |
| Gaudi::Property< double > | m_rout {this, "rout", {-1.0}, "Radius of outer layer for keylayer definition"} |
| |
| Gaudi::Property< bool > | m_approxMath {this, "approxMath", {false}, "Use approximate math to emulate possible firmware"} |
| |
| Gaudi::Property< double > | m_d0pad {this, "D0Pad", 0.0, "Extra phi padding from d0 resolution"} |
| |
| Gaudi::Property< double > | m_phipad {this, "PhiPad", 0.0, "Extra phi padding from phi resolution"} |
| |
| Gaudi::Property< double > | m_qptpad {this, "QPtPad", 0.0, "Extra phi padding from q/pT resolution"} |
| |
| Gaudi::Property< double > | m_z0pad {this, "Z0Pad", 0.0, "Extra eta padding from z0 resolution"} |
| |
| Gaudi::Property< double > | m_etapad {this, "EtaPad", 0.0, "Extra eta padding from eta resolution"} |
| |
| Gaudi::Property< unsigned > | m_region {this, "region", 0, "Region number, needed to write out lookup tables for test vectors"} |
| |
| Gaudi::Property< std::vector< double > > | m_slPerEtaMod |
| |
| Gaudi::Property< double > | m_phiOffset {this, "PhiOffset", 0.0, "Phi offset between local and global parameters (avoids phi wrap around effects in region code)"} |
| |
| Gaudi::Property< unsigned > | m_fieldCorRegion { this, "fieldCorRegion", 2, "region for fieldCorrection"} |
| |
| Gaudi::Property< bool > | m_fieldCorrection {this, "fieldCorrection", true, "Use magnetic field correction for Hough transform"} |
| |
| FPGATrackSimKeyLayerTool | m_keylyrtool |
| |
| const std::vector< std::string > | m_parNames {"zR1", "zR2", "phiR1", "phiR2", "xm"} |
| |
| const std::vector< unsigned > | m_phipars {2, 3, 4} |
| |
| const std::vector< unsigned > | m_etapars {0, 1} |
| |
◆ etaResidual()
◆ getEtaLUTConsts()
Definition at line 209 of file FPGATrackSimKeyLayerBinDesc.cxx.
217 double z_in =
step.binCenter(0,
idx[0]);
218 double z_out =
step.binCenter(1,
idx[1]);
219 double dz_dr = (z_out - z_in) / (r_out - r_in);
224 double w_in =
step.binWidth(0) / 2.0;
225 double w_out =
step.binWidth(1) / 2.0;
226 double dw_dr = (w_out - w_in) / (r_out - r_in);
◆ getPhiLUTConsts()
Definition at line 175 of file FPGATrackSimKeyLayerBinDesc.cxx.
185 retv.
y = rotated_coords.y;
186 retv.x1p = rotated_coords.xy1p.first;
187 retv.y1p = rotated_coords.xy1p.second;
188 retv.cosb = rotated_coords.rotang.first;
189 retv.sinb = rotated_coords.rotang.second;
190 retv.x_m = keypars.
xm;
191 retv.x_factor = 4.0 * keypars.
xm / (rotated_coords.y * rotated_coords.y);
198 double w_in = r_in *
step.binWidth(2) / 2.0;
199 double w_out = r_out *
step.binWidth(3) / 2.0;
200 double w_x =
step.binWidth(4) / 2.0;
202 retv.w_x = 4.0 * w_x / ((r_out - r_in) * (r_out - r_in));
204 retv.dw_dr = (w_out - w_in) / (r_out - r_in);
◆ hitInBin()
Definition at line 41 of file FPGATrackSimKeyLayerBinDesc.cxx.
47 double hitr= storedhit.
hitptr->getR();
49 bool passesPhi =
true;
50 bool passesEta =
true;
54 bool isTruthBin = ((m_truthbin.size()>
step.stepNum())&&(m_truthbin[
step.stepNum()]==
idx));
63 half_xm_bin_pars.xm =
step.binWidth(4)/2.0;
66 double xrange = std::abs(xshift) +
r1 *
step.binWidth(2) / 2.0
67 + ((
r2*
step.binWidth(3) -
r1*
step.binWidth(2)) / (r2 - r1) * (hitr -
r1))/2.0;
70 ATH_MSG_ERROR(
"Negative xrange: " << std::abs(xshift) <<
" " << r1 *
step.binWidth(2) / 2.0 <<
" "
71 << ((r2*
step.binWidth(3) - r1*
step.binWidth(2)) / (r2 - r1) * (hitr - r1))/2.0);
75 double stripLength = 25.0;
77 if (!storedhit.
hitptr->isBarrel()) {
88 if (isTruthBin && !passesPhi)
ATH_MSG_DEBUG(
"Hit fails Phi cut, lyr=" << storedhit.
hitptr->getPhysLayer() <<
" "
92 <<
" " << hitr <<
" " << trackpars);
97 double fw_phiWindow = phiconsts.phiWindow( hitr);
99 ATH_MSG_VERBOSE(
"FW " << phiconsts.w_in <<
" " << phiconsts.dw_dr*(hitr-phiconsts.r_in) <<
" " << phiconsts.w_x*(hitr-phiconsts.r_in)*(phiconsts.r_out-hitr)
100 <<
" Orig: " << r1 *
step.binWidth(2) / 2.0 <<
" " << ((r2*
step.binWidth(3) - r1*
step.binWidth(2)) / (r2 - r1) * (hitr - r1))/2.0 <<
" " << std::abs(xshift));
109 double width_z_in =
step.binWidth(0)/2.0;
110 double width_z_out =
step.binWidth(1)/2.0;
111 double zrange = width_z_in + (width_z_out-width_z_in) * std::abs((hitr-r1))/(r2-r1);
115 double stripLength = 25.0;
117 if (!storedhit.
hitptr->isBarrel()) {
128 if (isTruthBin && !passesEta)
ATH_MSG_DEBUG(
"Hit fails Eta cut , lyr=" << storedhit.
hitptr->getPhysLayer() <<
" r=" << hitr <<
" "
133 double fw_etaShift = etaconsts.etaShift(storedhit.
hitptr->getZ(), hitr);
134 double fw_etaWindow = etaconsts.etaWindow( hitr);
142 if (isTruthBin && !(passesPhi && passesEta))
ATH_MSG_DEBUG(
"Hit in truth bin fails cuts: " <<
" passesPhi=" << passesPhi <<
" passesEta=" << passesEta);
144 return passesPhi && passesEta;
◆ initialize()
| StatusCode FPGATrackSimKeyLayerBinDesc::initialize |
( |
| ) |
|
|
overridevirtual |
Definition at line 25 of file FPGATrackSimKeyLayerBinDesc.cxx.
28 const std::vector<Gaudi::Details::PropertyBase*> props = this->getProperties();
29 for( Gaudi::Details::PropertyBase* prop : props ) {
30 if (prop->ownerTypeName()==this->type()) {
31 ATH_MSG_DEBUG(
"Property:\t" << prop->name() <<
"\t : \t"<< prop->toString());
38 return StatusCode::SUCCESS;
◆ keyparsToParSet()
◆ parNames()
| virtual const std::string& FPGATrackSimKeyLayerBinDesc::parNames |
( |
unsigned |
i | ) |
const |
|
inlineoverridevirtual |
◆ parSetToKeyPars()
◆ parSetToTrackPars()
◆ phiResidual()
◆ stepIsREta()
◆ stepIsRPhi()
◆ trackParsToParSet()
◆ writeLUTs()
Definition at line 256 of file FPGATrackSimKeyLayerBinDesc.cxx.
263 if (
step.isFirstStep()) {
266 sm.writeVar(
"r_in",r_in);
267 sm.writeVar(
"r_out",r_out);
280 sm.writeVar(
"phi_bin",
bin.idx());
282 sm.writeVar(
"y", phiconsts.y);
283 sm.writeVar(
"x1p", phiconsts.x1p);
284 sm.writeVar(
"y1p", phiconsts.y1p);
285 sm.writeVar(
"cosb", phiconsts.cosb);
286 sm.writeVar(
"sinb", phiconsts.sinb);
288 sm.writeVar(
"x_m", phiconsts.x_m);
289 sm.writeVar(
"x_factor", phiconsts.x_factor);
292 sm.writeVar(
"w_x", phiconsts.w_x);
293 sm.writeVar(
"w_in", phiconsts.w_in);
294 sm.writeVar(
"dw_dr", phiconsts.dw_dr);
300 sm.writeVar(
"nbins",
nbins);
316 sm.writeVar(
"z_bin",
bin.idx());
317 sm.writeVar(
"z_in", etaconsts.z_in);
318 sm.writeVar(
"dz_dr", etaconsts.dz_dr);
321 sm.writeVar(
"w_in", etaconsts.w_in);
322 sm.writeVar(
"dw_dr", etaconsts.dw_dr);
327 sm.writeVar(
"nbins",
nbins);
◆ m_approxMath
| Gaudi::Property<bool> FPGATrackSimKeyLayerBinDesc::m_approxMath {this, "approxMath", {false}, "Use approximate math to emulate possible firmware"} |
|
private |
◆ m_d0pad
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_d0pad {this, "D0Pad", 0.0, "Extra phi padding from d0 resolution"} |
|
private |
◆ m_etapad
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_etapad {this, "EtaPad", 0.0, "Extra eta padding from eta resolution"} |
|
private |
◆ m_etapars
| const std::vector<unsigned> FPGATrackSimKeyLayerBinDesc::m_etapars {0, 1} |
|
private |
◆ m_fieldCorrection
| Gaudi::Property<bool> FPGATrackSimKeyLayerBinDesc::m_fieldCorrection {this, "fieldCorrection", true, "Use magnetic field correction for Hough transform"} |
|
private |
◆ m_fieldCorRegion
| Gaudi::Property<unsigned> FPGATrackSimKeyLayerBinDesc::m_fieldCorRegion { this, "fieldCorRegion", 2, "region for fieldCorrection"} |
|
private |
◆ m_keylyrtool
◆ m_parNames
| const std::vector<std::string> FPGATrackSimKeyLayerBinDesc::m_parNames {"zR1", "zR2", "phiR1", "phiR2", "xm"} |
|
private |
◆ m_phiOffset
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_phiOffset {this, "PhiOffset", 0.0, "Phi offset between local and global parameters (avoids phi wrap around effects in region code)"} |
|
private |
◆ m_phipad
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_phipad {this, "PhiPad", 0.0, "Extra phi padding from phi resolution"} |
|
private |
◆ m_phipars
| const std::vector<unsigned> FPGATrackSimKeyLayerBinDesc::m_phipars {2, 3, 4} |
|
private |
◆ m_qptpad
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_qptpad {this, "QPtPad", 0.0, "Extra phi padding from q/pT resolution"} |
|
private |
◆ m_region
| Gaudi::Property<unsigned> FPGATrackSimKeyLayerBinDesc::m_region {this, "region", 0, "Region number, needed to write out lookup tables for test vectors"} |
|
private |
◆ m_rin
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_rin {this, "rin", {-1.0}, "Radius of inner layer for keylayer definition"} |
|
private |
◆ m_rout
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_rout {this, "rout", {-1.0}, "Radius of outer layer for keylayer definition"} |
|
private |
◆ m_slPerEtaMod
| Gaudi::Property<std::vector<double> > FPGATrackSimKeyLayerBinDesc::m_slPerEtaMod |
|
private |
Initial value:{
this,
"slPerEtaMod",
std::vector<double>{19.0, 24.0, 29.0, 32.0, 18.1, 27.1, 24.1, 15.1, 30.8,
30.8, 26.2, 32.2, 32.2, 26.2, 54.6, 54.6, 40.2, 60.2},
"Strip length per eta eta mod"
}
Definition at line 143 of file FPGATrackSimKeyLayerBinDesc.h.
◆ m_z0pad
| Gaudi::Property<double> FPGATrackSimKeyLayerBinDesc::m_z0pad {this, "Z0Pad", 0.0, "Extra eta padding from z0 resolution"} |
|
private |
The documentation for this class was generated from the following files:
void xrange(TH1 *h, bool symmetric)
const std::vector< unsigned > m_etapars
std::shared_ptr< const FPGATrackSimHit > hitptr
virtual double etaResidual(const FPGATrackSimBinUtil::ParSet &parset, FPGATrackSimHit const *hit) const override
Gaudi::Property< unsigned > m_fieldCorRegion
phiLUTConsts getPhiLUTConsts(const FPGATrackSimBinStep &step, const std::vector< unsigned > &idx) const
Gaudi::Property< double > m_rout
FPGATrackSimBinUtil::ParSet keyparsToParSet(const FPGATrackSimKeyLayerTool::KeyLyrPars &keypars) const
const std::vector< std::string > m_parNames
#define ATH_MSG_VERBOSE(x)
std::string to_string(const SectorProjector proj)
Gaudi::Property< double > m_etapad
virtual const FPGATrackSimTrackPars parSetToTrackPars(const FPGATrackSimBinUtil::ParSet &parset) const override
etaLUTConsts getEtaLUTConsts(const FPGATrackSimBinStep &step, const std::vector< unsigned > &idx) const
std::atomic< int > padding
Gaudi::Property< double > m_phiOffset
static double dPhidQOverPt(double hitr)
static double dPhiHitTrkFromPars(double r, const FPGATrackSimTrackPars &pars)
def etamod(flags, cells_name, *args, **kw)
const std::vector< unsigned > m_phipars
Gaudi::Property< double > m_phipad
Gaudi::Property< double > m_qptpad
Gaudi::Property< double > m_d0pad
Gaudi::Property< double > m_rin
bool stepIsREta(const FPGATrackSimBinStep &step) const
std::vector< std::string > remainder(const std::vector< std::string > &v1, const std::vector< std::string > &v2)
virtual double phiResidual(const FPGATrackSimBinUtil::ParSet &parset, FPGATrackSimHit const *hit) const override
FPGATrackSimKeyLayerTool m_keylyrtool
bool stepIsRPhi(const FPGATrackSimBinStep &step) const
static double dZdEta(double eta)
FPGATrackSimKeyLayerTool::KeyLyrPars parSetToKeyPars(const FPGATrackSimBinUtil::ParSet &parset) const
Gaudi::Property< double > m_z0pad
double fieldCorrection(unsigned region, double qoverpt, double r)
Gaudi::Property< bool > m_fieldCorrection
Gaudi::Property< std::vector< double > > m_slPerEtaMod
Gaudi::Property< unsigned > m_region