BOSS 7.0.9
BESIII Offline Software System
Loading...
Searching...
No Matches
MucCalibData.cxx
Go to the documentation of this file.
1/** @class MucCalibData
2 * Implementation of MucCalibData calibration TCDS class
3 */
4
6#include "GaudiKernel/MsgStream.h"
7namespace CalibData {
9
10 StatusCode MucCalibData::update(CalibBase1& other, MsgStream* log)
11 {
12 MucCalibData& other1 = dynamic_cast<MucCalibData& >(other);
13 std::cout<<"========================================"<<"\n"
14 <<"here is the update in the MucCalibData"<<"\n"
15 <<"=================================================="<<std::endl;
16 CalibBase1::update(other, log);
22 //set the Calibration Data
23 for(int i=0;i<LAYER_MAX;i++) {
24 setLayerEff(other1.getLayerEff(i),i);
25 setLayerNos(other1.getLayerNos(i),i);
26 setLayerCnt(other1.getLayerCnt(i),i);
28 for(int j=0;j<CLST_MAX;j++){
29 setLayerClstPro(other1.getLayerClstPro(i,j),i,j);
30 }
31 }
32 for(int i=0;i<PART_MAX;i++) {
33 for(int j=0;j<SEGMENT_MAX;j++){
34 for(int k=0;k<LAYER_MAX;k++){
35 setBoxEff(other1.getBoxEff(i,j,k),i,j,k);
36 setBoxNos(other1.getBoxNos(i,j,k),i,j,k);
37 setBoxCnt(other1.getBoxCnt(i,j,k),i,j,k);
38 setBoxNosRatio(other1.getBoxNosRatio(i,j,k),i,j,k);
39 for(int l=0;l<CLST_MAX;l++){
40 setBoxClstPro(other1.getBoxClstPro(i,j,k,l),i,j,k,l);
41 }
42 }
43 }
44 }
45 for(int i=0;i<PART_MAX;i++){
46 for(int j=0;j<SEGMENT_MAX;j++){
47 for(int k=0;k<LAYER_MAX;k++){
48 for(int l=0;l<STRIP_INBOX_MAX;l++){
49 setStripEff(other1.getStripEff(i,j,k,l),i,j,k,l);
50 setStripNos(other1.getStripNos(i,j,k,l),i,j,k,l);
51 setStripCnt(other1.getStripCnt(i,j,k,l),i,j,k,l);
52 setStripNosRatio(other1.getStripNosRatio(i,j,k,l),i,j,k,l);
53 }
54 }
55 }
56 }
57 std::cout<<"updata complete================="<<std::endl;
58 return StatusCode::SUCCESS;
59}
60
61 //set the Calibration Data
62
63/* int MucCalibData::setDefault()
64 {
65
66 m_uniformEff = DEFAULT_EFF;
67 m_uniformNos = DEFAULT_NOS;
68 m_uniformClst = DEFAULT_CLST;
69
70 for(int i=0; i<LAYER_MAX; i++)
71 {
72 m_layerEff[i] = DEFAULT_EFF;
73 m_layerNos[i] = DEFAULT_NOS;
74 for(int j=0; j<CLST_MAX; j++)
75 m_layerClstPro[i][j] = DEFAULT_CLST_PRO[j];
76 }
77
78 for(int i=0; i<PART_MAX; i++)
79 {
80 for(int j=0; j<((i==1)?B_SEG_NUM:E_SEG_NUM); j++)
81 {
82 for(int k=0; k<((i==1)?B_LAY_NUM:E_LAY_NUM); k++)
83 {
84 m_boxEff[i][j][k] = DEFAULT_EFF;
85 m_boxNos[i][j][k] = DEFAULT_NOS;
86 for(int n=0; n<CLST_MAX; n++)
87 m_boxClstPro[i][j][k][n] = DEFAULT_CLST_PRO[n];
88 }
89 }
90 }
91
92 int strip_max;
93 for(int i=0; i<PART_MAX; i++)
94 {
95 for(int j=0; j<((i==1)?B_SEG_NUM:E_SEG_NUM); j++)
96 {
97 for(int k=0; k<((i==1)?B_LAY_NUM:E_LAY_NUM); k++)
98 {
99 strip_max = m_ptrIdTr->GetStripMax(i, j, k);
100 for(int n=0; n<strip_max; n++)
101 {
102 m_stripEff[i][j][k][n] = DEFAULT_EFF;
103 m_stripNos[i][j][k][n] = DEFAULT_NOS;
104 }
105 }
106 }
107 }
108
109 return 1;
110}
111
112*/
113
114
115}
virtual StatusCode update(CalibBase1 &obj, MsgStream *)
Definition: CalibBase1.cxx:33
void setLayerClstPro(const double layerpro, int i, int j)
Definition: MucCalibData.h:95
double getLayerNosRatio(int layer) const
Definition: MucCalibData.h:44
void setLayerNos(const double layernos, int i)
Definition: MucCalibData.h:92
double getUniformNosRatio() const
Definition: MucCalibData.h:40
double getUniformEff() const
Definition: MucCalibData.h:36
double getBoxNos(int part, int segment, int layer) const
Definition: MucCalibData.h:61
void setLayerCnt(const double layercnt, int i)
Definition: MucCalibData.h:93
double getBoxClstPro(int part, int segment, int layer, int size) const
Definition: MucCalibData.h:64
double getStripNos(int part, int segment, int layer, int strip) const
Definition: MucCalibData.h:79
double getStripCnt(int part, int segment, int layer, int strip) const
Definition: MucCalibData.h:80
void setUniformCnt(double cnt)
Definition: MucCalibData.h:87
double getBoxNosRatio(int part, int segment, int layer) const
Definition: MucCalibData.h:63
void setUniformClst(double clst)
Definition: MucCalibData.h:86
double getStripNosRatio(int part, int segment, int layer, int strip) const
Definition: MucCalibData.h:81
void setBoxCnt(const double boxcnt, int i, int j, int k)
Definition: MucCalibData.h:99
void setStripNos(const double stripnos, int i, int j, int k, int l)
Definition: MucCalibData.h:104
double getBoxCnt(int part, int segment, int layer) const
Definition: MucCalibData.h:62
void setBoxNosRatio(const double boxratio, int i, int j, int k)
Definition: MucCalibData.h:100
void setStripEff(const double stripeff, int i, int j, int k, int l)
Definition: MucCalibData.h:103
void setUniformEff(double eff)
Definition: MucCalibData.h:84
double getUniformCnt() const
Definition: MucCalibData.h:39
void setStripNosRatio(const double stripnosratio, int i, int j, int k, int l)
Definition: MucCalibData.h:106
virtual StatusCode update(CalibBase1 &other, MsgStream *log)
void setStripCnt(const double stripcnt, int i, int j, int k, int l)
Definition: MucCalibData.h:105
void setUniformNosRatio(double nosratio)
Definition: MucCalibData.h:88
double getBoxEff(int part, int segment, int layer) const
Definition: MucCalibData.h:60
double getLayerNos(int layer) const
Definition: MucCalibData.h:43
void setBoxEff(const double boxeff, int i, int j, int k)
Definition: MucCalibData.h:97
double getLayerClstPro(int layer, int size) const
Definition: MucCalibData.h:46
double getStripEff(int part, int segment, int layer, int strip) const
Definition: MucCalibData.h:78
double getLayerEff(int layer) const
Definition: MucCalibData.h:42
double getLayerCnt(int layer) const
Definition: MucCalibData.h:45
double getUniformClst() const
Definition: MucCalibData.h:38
void setBoxNos(const double boxnos, int i, int j, int k)
Definition: MucCalibData.h:98
void setLayerEff(const double layereff, int i)
Definition: MucCalibData.h:91
void setLayerNosRatio(const double layernosratio, int i)
Definition: MucCalibData.h:94
void setBoxClstPro(const double boxpro, int i, int j, int k, int l)
Definition: MucCalibData.h:101