ATLAS Offline Software
Public Member Functions | Private Member Functions | Private Attributes | List of all members
ALFA_MDOverlap Class Reference

#include <ALFA_MDOverlap.h>

Inheritance diagram for ALFA_MDOverlap:
Collaboration diagram for ALFA_MDOverlap:

Public Member Functions

 ALFA_MDOverlap ()
 
 ~ALFA_MDOverlap ()
 
StatusCode Initialize (const eRPotName &eRPName, const std::list< MDHIT > &ListMDHits, Float_t faMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT], Float_t fbMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT], Float_t fzMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT])
 
StatusCode Execute ()
 
StatusCode Finalize (Float_t &fRecXPos, Float_t &fRecYPos)
 
void GetData (Int_t(&iFibSel)[ALFALAYERSCNT *ALFAPLATESCNT])
 
bool msgLvl (const MSG::Level lvl) const
 Test the output level. More...
 
MsgStream & msg () const
 The standard message stream. More...
 
MsgStream & msg (const MSG::Level lvl) const
 The standard message stream. More...
 
void setLevel (MSG::Level lvl)
 Change the current logging level. More...
 

Private Member Functions

void HistInitialize ()
 
void HistFinalize ()
 
StatusCode SelectHitInLayer ()
 
StatusCode Overlap ()
 
void initMessaging () const
 Initialize our message level and MessageSvc. More...
 

Private Attributes

Int_t m_iRPot
 
Int_t m_iTBins
 
Int_t m_iRBins
 
Float_t m_fbMinU
 
Float_t m_fbMinV
 
Float_t m_fFiberD
 
Float_t m_fzStep
 
Float_t m_fTLow
 
Float_t m_fTHigh
 
Float_t m_fRLow
 
Float_t m_fRHigh
 
Float_t m_fHitBU
 
Float_t m_fHitBV
 
Float_t m_fRecXPos
 
Float_t m_fRecYPos
 
Int_t m_iFHits [ALFALAYERSCNT *ALFAPLATESCNT]
 
Float_t m_faMD [ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
 
Float_t m_fbMD [ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
 
Float_t m_fzMD [ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
 
TH2D * m_histU_PT
 
TH2D * m_histV_PT
 
std::list< MDHITm_ListMDHits
 
std::string m_nm
 Message source name. More...
 
boost::thread_specific_ptr< MsgStream > m_msg_tls
 MsgStream instance (a std::cout like with print-out levels) More...
 
std::atomic< IMessageSvc * > m_imsg { nullptr }
 MessageSvc pointer. More...
 
std::atomic< MSG::Level > m_lvl { MSG::NIL }
 Current logging level. More...
 
std::atomic_flag m_initialized ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT
 Messaging initialized (initMessaging) More...
 

Detailed Description

Definition at line 25 of file ALFA_MDOverlap.h.

Constructor & Destructor Documentation

◆ ALFA_MDOverlap()

ALFA_MDOverlap::ALFA_MDOverlap ( )

Definition at line 8 of file ALFA_MDOverlap.cxx.

8  :
9  AthMessaging("ALFA_MDOverlap"),
10  m_iRPot (0),
11  m_iTBins (0),
12  m_iRBins (0),
13  m_fbMinU (0.0),
14  m_fbMinV (0.0),
15  m_fFiberD (0.0),
16  m_fzStep (0.0),
17  m_fTLow (0.0),
18  m_fTHigh (0.0),
19  m_fRLow (0.0),
20  m_fRHigh (0.0),
21  m_fHitBU (0.0),
22  m_fHitBV (0.0),
23  m_fRecXPos (0.0),
24  m_fRecYPos (0.0),
25  m_histU_PT (nullptr),
26  m_histV_PT (nullptr)
27 {
28  memset(&m_iFHits, 0, sizeof(m_iFHits));
29 }

◆ ~ALFA_MDOverlap()

ALFA_MDOverlap::~ALFA_MDOverlap ( )

Definition at line 31 of file ALFA_MDOverlap.cxx.

32 {
33 
34 }

Member Function Documentation

◆ Execute()

StatusCode ALFA_MDOverlap::Execute ( )

Definition at line 90 of file ALFA_MDOverlap.cxx.

91 {
92  StatusCode sc;
93 
94  // SELECT CANDIDATE HITS
95  sc = SelectHitInLayer();
96  if(sc.isFailure())
97  {
98  ATH_MSG_ERROR("hit selection failure");
99  return sc;
100  }
101 
102  sc = Overlap();
103  if(sc.isFailure())
104  {
105  ATH_MSG_ERROR("Overlap failure");
106  return sc;
107  }
108 
109 
110  return StatusCode::SUCCESS;
111 }

◆ Finalize()

StatusCode ALFA_MDOverlap::Finalize ( Float_t &  fRecXPos,
Float_t &  fRecYPos 
)

Definition at line 113 of file ALFA_MDOverlap.cxx.

114 {
115  fRecXPos = m_fRecXPos;
116  fRecYPos = m_fRecYPos;
117 
118  HistFinalize();
119 
120  return StatusCode::SUCCESS;
121 }

◆ GetData()

void ALFA_MDOverlap::GetData ( Int_t(&)  iFibSel[ALFALAYERSCNT *ALFAPLATESCNT])

Definition at line 439 of file ALFA_MDOverlap.cxx.

440 {
441  for (Int_t iLayer=0; iLayer<ALFALAYERSCNT*ALFAPLATESCNT; iLayer++)
442  {
443  iFibSel[iLayer] = m_iFHits[iLayer];
444  }
445 }

◆ HistFinalize()

void ALFA_MDOverlap::HistFinalize ( )
private

Definition at line 433 of file ALFA_MDOverlap.cxx.

434 {
435  delete m_histU_PT;
436  delete m_histV_PT;
437 }

◆ HistInitialize()

void ALFA_MDOverlap::HistInitialize ( )
private

Definition at line 427 of file ALFA_MDOverlap.cxx.

428 {
429  m_histU_PT = new TH2D("histU_PT", "Hough Trans. of U", m_iTBins, m_fTLow, m_fTHigh, m_iRBins, m_fRLow, m_fRHigh);
430  m_histV_PT = new TH2D("histV_PT", "Hough Trans. of V", m_iTBins, m_fTLow, m_fTHigh, m_iRBins, m_fRLow, m_fRHigh);
431 }

◆ Initialize()

StatusCode ALFA_MDOverlap::Initialize ( const eRPotName eRPName,
const std::list< MDHIT > &  ListMDHits,
Float_t  faMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT],
Float_t  fbMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT],
Float_t  fzMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT] 
)

Definition at line 36 of file ALFA_MDOverlap.cxx.

37 {
38  m_iRPot = eRPName - 1;
39  m_ListMDHits = ListMDHits;
40 
41  for (Int_t iLayer = 0; iLayer < ALFALAYERSCNT*ALFAPLATESCNT; iLayer++)
42  {
43  for (Int_t iFiber = 0; iFiber < ALFAFIBERSCNT; iFiber++)
44  {
45  m_faMD[iLayer][iFiber] = faMD[m_iRPot][iLayer][iFiber];
46  m_fbMD[iLayer][iFiber] = fbMD[m_iRPot][iLayer][iFiber];
47  m_fzMD[iLayer][iFiber] = fzMD[m_iRPot][iLayer][iFiber];
48  }
49  }
50 
51  Float_t fzBase = m_fzMD[0][0];
52  m_fbMinU = 1111.0;
53  m_fbMinV = 1111.0;
54 
55  for (Int_t iLayer = 0; iLayer < ALFAPLATESCNT*ALFALAYERSCNT; iLayer++)
56  {
57  for (Int_t iFiber = 0; iFiber < ALFAFIBERSCNT; iFiber++)
58  {
59  if ((m_fbMD[iLayer][iFiber] < m_fbMinU) && m_faMD[iLayer][iFiber] < 0)
60  {
61  m_fbMinU = m_fbMD[iLayer][iFiber];
62  }
63 
64  if ((m_fbMD[iLayer][iFiber] < m_fbMinV) && m_faMD[iLayer][iFiber] > 0)
65  {
66  m_fbMinV = m_fbMD[iLayer][iFiber];
67  }
68 
69  // rescale zPos
70  m_fzMD[iLayer][iFiber] -= fzBase;
71  }
72  }
73 
74  m_fFiberD = 0.7071;
75  m_fzStep = 2.0;
76 
77  m_fTLow = (1.0/4.0)*M_PI;
78  m_fTHigh = (3.0/4.0)*M_PI;
79  m_fRLow = 0.0;
80  m_fRHigh = 64.0;
81  m_iTBins = 100;
82  m_iRBins = 64;
83 
84 
86 
87  return StatusCode::SUCCESS;
88 }

◆ initMessaging()

void AthMessaging::initMessaging ( ) const
privateinherited

Initialize our message level and MessageSvc.

This method should only be called once.

Definition at line 39 of file AthMessaging.cxx.

40 {
42  m_lvl = m_imsg ?
43  static_cast<MSG::Level>( m_imsg.load()->outputLevel(m_nm) ) :
44  MSG::INFO;
45 }

◆ msg() [1/2]

MsgStream & AthMessaging::msg ( ) const
inlineinherited

The standard message stream.

Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.

Definition at line 164 of file AthMessaging.h.

165 {
166  MsgStream* ms = m_msg_tls.get();
167  if (!ms) {
168  if (!m_initialized.test_and_set()) initMessaging();
169  ms = new MsgStream(m_imsg,m_nm);
170  m_msg_tls.reset( ms );
171  }
172 
173  ms->setLevel (m_lvl);
174  return *ms;
175 }

◆ msg() [2/2]

MsgStream & AthMessaging::msg ( const MSG::Level  lvl) const
inlineinherited

The standard message stream.

Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.

Definition at line 179 of file AthMessaging.h.

180 { return msg() << lvl; }

◆ msgLvl()

bool AthMessaging::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Test the output level.

Parameters
lvlThe message level to test against
Returns
boolean Indicating if messages at given level will be printed
Return values
trueMessages at level "lvl" will be printed

Definition at line 151 of file AthMessaging.h.

152 {
153  if (!m_initialized.test_and_set()) initMessaging();
154  if (m_lvl <= lvl) {
155  msg() << lvl;
156  return true;
157  } else {
158  return false;
159  }
160 }

◆ Overlap()

StatusCode ALFA_MDOverlap::Overlap ( )
private

Definition at line 272 of file ALFA_MDOverlap.cxx.

273 {
274  Int_t n_p = 0;
275  Int_t n_n = 0;
276  Float_t faMeanP = 0;
277  Float_t fbMeanP = 0;
278  Float_t faMeanN = 0;
279  Float_t fbMeanN = 0;
280 
281  Float_t fbMinP, fbMaxP, fbMinN, fbMaxN;
282  Float_t fActive = 0.48;
283  Float_t fHalfStep = 0;
284 
285  for(Int_t iLayer = 0; iLayer < ALFAPLATESCNT*ALFALAYERSCNT; iLayer++)
286  {
287  if(m_iFHits[iLayer]!= -9999)
288  {
289  if(m_faMD[iLayer][0] >= 0)
290  {
291  fbMeanP += m_fbMD[iLayer][m_iFHits[iLayer]];
292  ++n_p;
293  }
294  else
295  {
296  fbMeanN += m_fbMD[iLayer][m_iFHits[iLayer]];
297  ++n_n;
298  }
299  }
300  }
301 
302  if ((n_p >= 1) && (n_n >= 1))
303  {
304  fbMeanP = fbMeanP / n_p + 0.07071;
305  fbMeanN = fbMeanN / n_n - 0.07071;
306  }
307 
308  // these mean b values are just used to generate reasonable start values
309  // and to avoid that one starts from a bad (i.e. cross talk) fiber
310  fbMinP = fbMeanP + fActive;
311  fbMaxP = fbMeanP - fActive;
312  fbMinN = fbMeanN + fActive;
313  fbMaxN = fbMeanN - fActive;
314 
315  Int_t iLayMinU = -9999;
316  Int_t iLayMaxU = -9999;
317  Int_t iLayMinV = -9999;
318  Int_t iLayMaxV = -9999;
319 
320  // now find minimum overlap in b values, separately for positive and
321  // negative slopes
322 
323  n_p = 0;
324  n_n = 0;
325  for(Int_t iLayer = 0; iLayer < ALFAPLATESCNT*ALFALAYERSCNT; iLayer++)
326  {
327  if(iLayer>=0 && m_iFHits[iLayer]!= -9999)
328  {
329  if(m_faMD[iLayer][0] >= 0)
330  {
331  fHalfStep = fabs(0.5*fActive/sin(atan(m_faMD[iLayer][m_iFHits[iLayer]])));
332 
333  if (m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep > fbMaxP)
334  {
335  if (fbMinP > m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep)
336  {
337  fbMinP = m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep;
338  iLayMinU = iLayer;
339  }
340  }
341 
342  if (m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep < fbMinP)
343  {
344  if (fbMaxP > m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep)
345  {
346  }
347  else
348  {
349  fbMaxP = m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep;
350  iLayMaxU = iLayer;
351  }
352  }
353 
354  faMeanP = faMeanP + m_faMD[iLayer][m_iFHits[iLayer]];
355  ++n_p;
356  }
357  else
358  {
359  fHalfStep = fabs(0.5*fActive/sin(atan(m_faMD[iLayer][m_iFHits[iLayer]])));
360 
361  if (m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep > fbMaxN)
362  {
363  if (fbMinN > m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep)
364  {
365  fbMinN =m_fbMD[iLayer][m_iFHits[iLayer]] + fHalfStep;
366  iLayMinV = iLayer;
367  }
368  }
369 
370  if (m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep < fbMinN)
371  {
372  if (fbMaxN > m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep)
373  {
374  }
375  else
376  {
377  fbMaxN = m_fbMD[iLayer][m_iFHits[iLayer]] - fHalfStep;
378  iLayMaxV = iLayer;
379  }
380  }
381 
382  faMeanN = faMeanN + m_faMD[iLayer][m_iFHits[iLayer]];
383  ++n_n;
384  }
385  }
386  }
387 
388  Double_t fPolyX[4];
389  Double_t fPolyY[4];
390 
391 // Float_t OL_x;
392 // Float_t OL_y;
393 
394  if (iLayMinU>=0 && iLayMaxU>=0 && iLayMinV>=0 && iLayMaxV>=0)
395  {
396  fPolyX[0] = (m_fbMD[iLayMinU][m_iFHits[iLayMinU]] - m_fbMD[iLayMinV][m_iFHits[iLayMinV]])/(m_faMD[iLayMinV][m_iFHits[iLayMinV]] - m_faMD[iLayMinU][m_iFHits[iLayMinU]]);
397  fPolyY[0] = m_faMD[iLayMinU][m_iFHits[iLayMinU]]*fPolyX[0] + m_fbMD[iLayMinU][m_iFHits[iLayMinU]] + fActive*0.707/2.0;
398 
399  fPolyX[1] = (m_fbMD[iLayMinU][m_iFHits[iLayMinU]] - m_fbMD[iLayMaxV][m_iFHits[iLayMaxV]] + fActive*0.707)/(m_faMD[iLayMaxV][m_iFHits[iLayMaxV]] - m_faMD[iLayMinU][m_iFHits[iLayMinU]]);
400  fPolyY[1] = m_faMD[iLayMinU][m_iFHits[iLayMinU]]*fPolyX[1] + m_fbMD[iLayMinU][m_iFHits[iLayMinU]] + fActive*0.707/2.0;
401 
402  fPolyX[2] = (m_fbMD[iLayMaxU][m_iFHits[iLayMaxU]] - m_fbMD[iLayMinV][m_iFHits[iLayMinV]] - fActive*0.707)/(m_faMD[iLayMinV][m_iFHits[iLayMinV]] - m_faMD[iLayMaxU][m_iFHits[iLayMaxU]]);
403  fPolyY[2] = m_faMD[iLayMaxU][m_iFHits[iLayMaxU]]*fPolyX[2] + m_fbMD[iLayMaxU][m_iFHits[iLayMaxU]] - fActive*0.707/2.0;
404 
405  fPolyX[3] = (m_fbMD[iLayMaxU][m_iFHits[iLayMaxU]] - m_fbMD[iLayMaxV][m_iFHits[iLayMaxV]])/(m_faMD[iLayMaxV][m_iFHits[iLayMaxV]] - m_faMD[iLayMaxU][m_iFHits[iLayMaxU]]);
406  fPolyY[3] = m_faMD[iLayMaxU][m_iFHits[iLayMaxU]]*fPolyX[3] + m_fbMD[iLayMaxU][m_iFHits[iLayMaxU]] - fActive*0.707/2.0;
407 
408  m_fRecXPos = (fPolyX[0] + fPolyX[1] + fPolyX[2] + fPolyX[3])/4.0;
409  m_fRecYPos = (fPolyY[0] + fPolyY[1] + fPolyY[2] + fPolyY[3])/4.0;
410 
411 // OL_x = (fabs(fPolyX[0] - m_fRecXPos) + fabs(fPolyX[1] - m_fRecXPos) + fabs(fPolyX[2] - m_fRecXPos) + fabs(fPolyX[3] - m_fRecXPos))/4.0;
412 // OL_y = (fabs(fPolyY[0] - m_fRecYPos) + fabs(fPolyY[1] - m_fRecYPos) + fabs(fPolyY[2] - m_fRecYPos) + fabs(fPolyY[3] - m_fRecYPos))/4.0;
413  }
414  else
415  {
416  m_fRecXPos = -9999.0;
417  m_fRecYPos = -9999.0;
418 
419 // OL_x = -9999.0;
420 // OL_y = -9999.0;
421  }
422 
423  return StatusCode::SUCCESS;
424 }

◆ SelectHitInLayer()

StatusCode ALFA_MDOverlap::SelectHitInLayer ( )
private

Definition at line 123 of file ALFA_MDOverlap.cxx.

124 {
125  // Reset Histograms
126  m_histU_PT->Reset();
127  m_histV_PT->Reset();
128 
129  // U (V) vs Z and Hough Transformed 2D histograms
130  Float_t fU = 0;
131  Float_t fZ = 0;
132  Float_t fRadius = 0;
133  Float_t fTheta = 0;
134 
135  FIBERS structFibers;
136  std::map<int, FIBERS> mapLayers;
137 
138  std::list<int>::iterator iterFiber;
139  Int_t iHitFiber;
140 
141  mapLayers.clear();
142 
143  std::list<MDHIT>::const_iterator iter;
144  for (iter=m_ListMDHits.begin(); iter!=m_ListMDHits.end(); ++iter)
145  {
146  if (m_iRPot == (*iter).iRPot)
147  {
148  if(mapLayers.find((*iter).iPlate)==mapLayers.end())
149  {
150  structFibers.ListFibers.clear();
151 
152  mapLayers.insert(std::pair<int, FIBERS>((*iter).iPlate, structFibers));
153  mapLayers[(*iter).iPlate].ListFibers.push_back((*iter).iFiber);
154  }
155  else
156  {
157  mapLayers[(*iter).iPlate].ListFibers.push_back((*iter).iFiber);
158  }
159  }
160  }
161 
162  for (Int_t iLayer = 0; iLayer < ALFALAYERSCNT*ALFAPLATESCNT; iLayer++)
163  {
164  for (iterFiber=mapLayers[iLayer].ListFibers.begin(); iterFiber!=mapLayers[iLayer].ListFibers.end(); ++iterFiber)
165  {
166  iHitFiber = *iterFiber;
167 
168  if (fmod((double)iLayer,(double)2) == 0) // for U-fibers
169  {
170  fU = (m_fbMD[iLayer][iHitFiber]-m_fbMinU)/m_fFiberD;
171  fZ = m_fzMD[iLayer][iHitFiber]/m_fzStep + 0.5;
172 
173  for(Int_t k=0; k < m_iTBins; k++)
174  {
175  fTheta = m_fTLow + (k+0.5)*(m_fTHigh-m_fTLow)/m_iTBins;
176  fRadius = fZ*cos(fTheta)+fU*sin(fTheta);
177 
178  m_histU_PT->Fill(fTheta, fRadius, 1.0);
179  }
180  }
181  else // for V-fibers
182  {
183  fU = (m_fbMD[iLayer][iHitFiber]-m_fbMinV)/m_fFiberD;
184  fZ = (m_fzMD[iLayer][iHitFiber]+1.0)/m_fzStep + 0.5;
185 
186  for(Int_t k=0; k < m_iTBins; k++)
187  {
188  fTheta = m_fTLow + (k+0.5)*(m_fTHigh-m_fTLow)/m_iTBins;
189  fRadius = fZ*cos(fTheta)+fU*sin(fTheta);
190 
191  m_histV_PT->Fill(fTheta, fRadius, 1.0);
192  }
193  }
194  }
195  }
196 
197  // Get maximumbin from PT histograms and determine seed track
198  Int_t iULocMax, iULocMay, iULocMaz;
199  Int_t iVLocMax, iVLocMay, iVLocMaz;
200 
201  m_histU_PT->GetMaximumBin(iULocMax, iULocMay, iULocMaz);
202  m_histV_PT->GetMaximumBin(iVLocMax, iVLocMay, iVLocMaz);
203 
204  // Select Hits closest to seed track ( dr < 2.0 )
205  Float_t fRMinU, fRMinV, fRTmp, fRdr;
206 
207  Float_t fRLineU = m_fRLow + (iULocMay-0.5)*(m_fRHigh-m_fRLow)/m_iRBins; // -0.5 since bins start with 1 (first bin, second...)
208  Float_t fRLineV = m_fRLow + (iVLocMay-0.5)*(m_fRHigh-m_fRLow)/m_iRBins;
209 
210  Double_t fTLineU = m_fTLow + (iULocMax-0.5)*(m_fTHigh-m_fTLow)/m_iTBins;
211  Double_t fTLineV = m_fTLow + (iVLocMax-0.5)*(m_fTHigh-m_fTLow)/m_iTBins;
212 
213  Float_t fAlphaU = -cos(fTLineU)/sin(fTLineU);
214  Float_t fAlphaV = -cos(fTLineV)/sin(fTLineV);
215 
216  Float_t fBetaU = fRLineU/sin(fTLineU);
217  Float_t fBetaV = fRLineV/sin(fTLineV);
218 
219  Float_t fBUMin = fAlphaU*0.0 + fBetaU;
220  Float_t fBUMax = fAlphaU*19.0 + fBetaU;
221 
222  Float_t fBVMin = fAlphaV*1.0 + fBetaV;
223  Float_t fBVMax = fAlphaV*20.0 + fBetaV;
224 
225  m_fHitBU = (fBUMax-fBUMin)/2.0 + fBUMin;
226  m_fHitBV = (fBVMax-fBVMin)/2.0 + fBVMin;
227 
228  for (Int_t iLayer = 0; iLayer < ALFALAYERSCNT*ALFAPLATESCNT; iLayer++)
229  {
230  fRMinU = 2.0;
231  fRMinV = 2.0;
232  m_iFHits[iLayer] = -9999;
233 
234  for (iterFiber=mapLayers[iLayer].ListFibers.begin(); iterFiber!=mapLayers[iLayer].ListFibers.end(); ++iterFiber)
235  {
236  iHitFiber = *iterFiber;
237 
238  if (fmod((double)iLayer,(double)2) == 0) // for U-fibers
239  {
240  fU = (m_fbMD[iLayer][iHitFiber]-m_fbMinU)/m_fFiberD;
241  fZ = m_fzMD[iLayer][iHitFiber]/m_fzStep + 0.5;
242 
243  fRTmp = fZ*cos(fTLineU) + fU*sin(fTLineU);
244  fRdr = fabs(fRLineU - fRTmp);
245 
246  if (fRdr < fRMinU)
247  {
248  fRMinU = fRdr;
249  m_iFHits[iLayer] = iHitFiber;
250  }
251  }
252  else // for V-fibers
253  {
254  fU = (m_fbMD[iLayer][iHitFiber]-m_fbMinV)/m_fFiberD;
255  fZ = (m_fzMD[iLayer][iHitFiber]+1.0)/m_fzStep + 0.5;
256 
257  fRTmp = fZ*cos(fTLineV) + fU*sin(fTLineV);
258  fRdr = fabs(fRLineV - fRTmp);
259 
260  if (fRdr < fRMinV)
261  {
262  fRMinV = fRdr;
263  m_iFHits[iLayer] = iHitFiber;
264  }
265  }
266  }
267  }
268 
269  return StatusCode::SUCCESS;
270 }

◆ setLevel()

void AthMessaging::setLevel ( MSG::Level  lvl)
inherited

Change the current logging level.

Use this rather than msg().setLevel() for proper operation with MT.

Definition at line 28 of file AthMessaging.cxx.

29 {
30  m_lvl = lvl;
31 }

Member Data Documentation

◆ ATLAS_THREAD_SAFE

std::atomic_flag m_initialized AthMessaging::ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT
mutableprivateinherited

Messaging initialized (initMessaging)

Definition at line 141 of file AthMessaging.h.

◆ m_faMD

Float_t ALFA_MDOverlap::m_faMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
private

Definition at line 59 of file ALFA_MDOverlap.h.

◆ m_fbMD

Float_t ALFA_MDOverlap::m_fbMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
private

Definition at line 60 of file ALFA_MDOverlap.h.

◆ m_fbMinU

Float_t ALFA_MDOverlap::m_fbMinU
private

Definition at line 39 of file ALFA_MDOverlap.h.

◆ m_fbMinV

Float_t ALFA_MDOverlap::m_fbMinV
private

Definition at line 40 of file ALFA_MDOverlap.h.

◆ m_fFiberD

Float_t ALFA_MDOverlap::m_fFiberD
private

Definition at line 41 of file ALFA_MDOverlap.h.

◆ m_fHitBU

Float_t ALFA_MDOverlap::m_fHitBU
private

Definition at line 49 of file ALFA_MDOverlap.h.

◆ m_fHitBV

Float_t ALFA_MDOverlap::m_fHitBV
private

Definition at line 50 of file ALFA_MDOverlap.h.

◆ m_fRecXPos

Float_t ALFA_MDOverlap::m_fRecXPos
private

Definition at line 52 of file ALFA_MDOverlap.h.

◆ m_fRecYPos

Float_t ALFA_MDOverlap::m_fRecYPos
private

Definition at line 53 of file ALFA_MDOverlap.h.

◆ m_fRHigh

Float_t ALFA_MDOverlap::m_fRHigh
private

Definition at line 47 of file ALFA_MDOverlap.h.

◆ m_fRLow

Float_t ALFA_MDOverlap::m_fRLow
private

Definition at line 46 of file ALFA_MDOverlap.h.

◆ m_fTHigh

Float_t ALFA_MDOverlap::m_fTHigh
private

Definition at line 45 of file ALFA_MDOverlap.h.

◆ m_fTLow

Float_t ALFA_MDOverlap::m_fTLow
private

Definition at line 44 of file ALFA_MDOverlap.h.

◆ m_fzMD

Float_t ALFA_MDOverlap::m_fzMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
private

Definition at line 61 of file ALFA_MDOverlap.h.

◆ m_fzStep

Float_t ALFA_MDOverlap::m_fzStep
private

Definition at line 42 of file ALFA_MDOverlap.h.

◆ m_histU_PT

TH2D* ALFA_MDOverlap::m_histU_PT
private

Definition at line 64 of file ALFA_MDOverlap.h.

◆ m_histV_PT

TH2D* ALFA_MDOverlap::m_histV_PT
private

Definition at line 65 of file ALFA_MDOverlap.h.

◆ m_iFHits

Int_t ALFA_MDOverlap::m_iFHits[ALFALAYERSCNT *ALFAPLATESCNT]
private

Definition at line 56 of file ALFA_MDOverlap.h.

◆ m_imsg

std::atomic<IMessageSvc*> AthMessaging::m_imsg { nullptr }
mutableprivateinherited

MessageSvc pointer.

Definition at line 135 of file AthMessaging.h.

◆ m_iRBins

Int_t ALFA_MDOverlap::m_iRBins
private

Definition at line 36 of file ALFA_MDOverlap.h.

◆ m_iRPot

Int_t ALFA_MDOverlap::m_iRPot
private

Definition at line 33 of file ALFA_MDOverlap.h.

◆ m_iTBins

Int_t ALFA_MDOverlap::m_iTBins
private

Definition at line 35 of file ALFA_MDOverlap.h.

◆ m_ListMDHits

std::list<MDHIT> ALFA_MDOverlap::m_ListMDHits
private

Definition at line 68 of file ALFA_MDOverlap.h.

◆ m_lvl

std::atomic<MSG::Level> AthMessaging::m_lvl { MSG::NIL }
mutableprivateinherited

Current logging level.

Definition at line 138 of file AthMessaging.h.

◆ m_msg_tls

boost::thread_specific_ptr<MsgStream> AthMessaging::m_msg_tls
mutableprivateinherited

MsgStream instance (a std::cout like with print-out levels)

Definition at line 132 of file AthMessaging.h.

◆ m_nm

std::string AthMessaging::m_nm
privateinherited

Message source name.

Definition at line 129 of file AthMessaging.h.


The documentation for this class was generated from the following files:
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
AthMessaging::m_lvl
std::atomic< MSG::Level > m_lvl
Current logging level.
Definition: AthMessaging.h:138
ALFA_MDOverlap::m_ListMDHits
std::list< MDHIT > m_ListMDHits
Definition: ALFA_MDOverlap.h:68
ALFA_MDOverlap::m_fzMD
Float_t m_fzMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
Definition: ALFA_MDOverlap.h:61
ALFA_MDOverlap::m_fRecXPos
Float_t m_fRecXPos
Definition: ALFA_MDOverlap.h:52
ALFA_MDOverlap::m_fRLow
Float_t m_fRLow
Definition: ALFA_MDOverlap.h:46
ALFA_MDOverlap::m_iTBins
Int_t m_iTBins
Definition: ALFA_MDOverlap.h:35
ALFAFIBERSCNT
#define ALFAFIBERSCNT
Definition: ALFA_constants.h:10
ALFA_MDOverlap::m_histU_PT
TH2D * m_histU_PT
Definition: ALFA_MDOverlap.h:64
ALFA_MDOverlap::m_iFHits
Int_t m_iFHits[ALFALAYERSCNT *ALFAPLATESCNT]
Definition: ALFA_MDOverlap.h:56
_FIBERS
Definition: ALFA_LocRec/ALFA_UserObjects.h:30
M_PI
#define M_PI
Definition: ActiveFraction.h:11
ALFA_MDOverlap::m_faMD
Float_t m_faMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
Definition: ALFA_MDOverlap.h:59
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
ALFA_MDOverlap::m_fbMD
Float_t m_fbMD[ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
Definition: ALFA_MDOverlap.h:60
AthMessaging::m_imsg
std::atomic< IMessageSvc * > m_imsg
MessageSvc pointer.
Definition: AthMessaging.h:135
python.SystemOfUnits.ms
int ms
Definition: SystemOfUnits.py:132
Athena::getMessageSvc
IMessageSvc * getMessageSvc(bool quiet=false)
Definition: getMessageSvc.cxx:20
ALFA_MDOverlap::m_fHitBV
Float_t m_fHitBV
Definition: ALFA_MDOverlap.h:50
drawFromPickle.atan
atan
Definition: drawFromPickle.py:36
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
ALFA_MDOverlap::m_fFiberD
Float_t m_fFiberD
Definition: ALFA_MDOverlap.h:41
ALFA_MDOverlap::Overlap
StatusCode Overlap()
Definition: ALFA_MDOverlap.cxx:272
ALFA_MDOverlap::m_fTLow
Float_t m_fTLow
Definition: ALFA_MDOverlap.h:44
AthMessaging::AthMessaging
AthMessaging()
Default constructor:
TrigConf::MSGTC::Level
Level
Definition: Trigger/TrigConfiguration/TrigConfBase/TrigConfBase/MsgStream.h:21
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
_FIBERS::ListFibers
std::list< int > ListFibers
Definition: ALFA_LocRec/ALFA_UserObjects.h:31
ALFA_MDOverlap::m_fbMinV
Float_t m_fbMinV
Definition: ALFA_MDOverlap.h:40
xAOD::double
double
Definition: CompositeParticle_v1.cxx:159
ALFALAYERSCNT
#define ALFALAYERSCNT
Definition: ALFA_constants.h:8
AthMessaging::msg
MsgStream & msg() const
The standard message stream.
Definition: AthMessaging.h:164
ALFA_MDOverlap::SelectHitInLayer
StatusCode SelectHitInLayer()
Definition: ALFA_MDOverlap.cxx:123
ALFA_MDOverlap::HistInitialize
void HistInitialize()
Definition: ALFA_MDOverlap.cxx:427
ALFA_MDOverlap::m_fRecYPos
Float_t m_fRecYPos
Definition: ALFA_MDOverlap.h:53
ALFA_MDOverlap::HistFinalize
void HistFinalize()
Definition: ALFA_MDOverlap.cxx:433
ALFA_MDOverlap::m_fTHigh
Float_t m_fTHigh
Definition: ALFA_MDOverlap.h:45
AthMessaging::m_nm
std::string m_nm
Message source name.
Definition: AthMessaging.h:129
ALFA_MDOverlap::m_fHitBU
Float_t m_fHitBU
Definition: ALFA_MDOverlap.h:49
ALFA_MDOverlap::m_fzStep
Float_t m_fzStep
Definition: ALFA_MDOverlap.h:42
ALFA_MDOverlap::m_iRPot
Int_t m_iRPot
Definition: ALFA_MDOverlap.h:33
AthMessaging::initMessaging
void initMessaging() const
Initialize our message level and MessageSvc.
Definition: AthMessaging.cxx:39
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
ALFA_MDOverlap::m_fbMinU
Float_t m_fbMinU
Definition: ALFA_MDOverlap.h:39
AthMessaging::m_msg_tls
boost::thread_specific_ptr< MsgStream > m_msg_tls
MsgStream instance (a std::cout like with print-out levels)
Definition: AthMessaging.h:132
ALFA_MDOverlap::m_iRBins
Int_t m_iRBins
Definition: ALFA_MDOverlap.h:36
ALFA_MDOverlap::m_fRHigh
Float_t m_fRHigh
Definition: ALFA_MDOverlap.h:47
ALFAPLATESCNT
#define ALFAPLATESCNT
Definition: ALFA_constants.h:9
fitman.k
k
Definition: fitman.py:528
ALFA_MDOverlap::m_histV_PT
TH2D * m_histV_PT
Definition: ALFA_MDOverlap.h:65