|
ATLAS Offline Software
|
Go to the documentation of this file.
32 m_ntpath=std::string(
"/NTUPLES/FILE1/OFCBINDIFF");
39 NTuple::Item<long> ntold, ntnew, ntcorr;
40 NTuple::Item<long> ntgain;
43 CHECK(
m_nt->addItem(
"OFCBinOld",ntold,-200,200));
44 CHECK(
m_nt->addItem(
"OFCBinNew",ntnew,-200,200));
45 CHECK(
m_nt->addItem(
"correction",ntcorr,0,200));
51 std::vector<std::map<HWIdentifier,float> > offsetMap;
52 if(
m_perFebMG) offsetMap.resize(2);
else offsetMap.resize(3);
55 rein.open(
m_fileName.c_str(),std::ifstream::in);
58 return StatusCode::FAILURE;
67 rein >> std::hex>>chidint >>std::dec>>
offset;
80 for(
unsigned i=0;
i<3; ++
i) offsetMap[
i][fid]=
offset[
i];
96 if(
sc!=StatusCode::SUCCESS) {
104 return StatusCode::FAILURE;
116 for (;
it!=it_e;++
it) {
124 int bindiff=td.
m_bin;
127 newCont->
set(chid,
gain,bindiff);
136 int barrel_ec = onlineID->
barrel_ec(chid);
138 if (
cabling->isOnlineConnected(chid)) {
150 newCont->
set(chid,
gain,bindiff);
158 if(fabs(
correction - imult*1.042) < 0.5) ntcorr = imult;
else ntcorr=(imult + mfac);
160 std::cout<<std::hex<<fid.
get_identifier32()<<
" "<<std::dec<<ntcorr<<std::endl;
164 newCont->
set(chid,
gain,bindiff);
172 if (
sc!=StatusCode::SUCCESS) {
174 return StatusCode::FAILURE;
181 return StatusCode::SUCCESS;
def retrieve(aClass, aKey=None)
std::string m_outputContainer
const LArFCAL_Base_ID * m_fcalId
const LArEM_ID * em_idHelper() const
access to EM idHelper
bool is_lar_fcal(Identifier id) const
This class factors out code common between LArEM_ID and LArEM_SuperCell_ID.
This class factors out code common between LArEM_ID and LArEM_SuperCell_ID.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Declaration of const iterator.
Identifier32 get_identifier32() const
Get the 32-bit version Identifier, will be invalid if >32 bits needed.
int module(const Identifier id) const
module [1,3]
int sampling(const Identifier id) const
return sampling according to :
LArOFCBinAlg(const std::string &name, ISvcLocator *pSvcLocator)
int barrel_ec(const HWIdentifier id) const
Return the position barrel or endcap of a hardware cell identifier: barrel_ec = [0,...
const SG::ReadCondHandleKey< LArOnOffIdMapping > & cablingKey() const
const LArHEC_ID * hec_idHelper() const
access to HEC idHelper
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
ConstConditionsMapIterator end(unsigned int gain) const
end of all channels for this gain
::StatusCode StatusCode
StatusCode definition for legacy code.
#define CHECK(...)
Evaluate an expression and check for errors.
bool is_lar_hec(Identifier id) const
Helper class for offline cell identifiers.
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
bool fillFromIdentifier(const HWIdentifier &id)
virtual StatusCode initialize()
Initialization done after creation or read back - derived classes may augment the functionality.
int sampling(const Identifier id) const
return sampling [0,3] (only 0 for supercells)
ConstConditionsMapIterator begin(unsigned int gain) const
get iterator for all channels for a gain
std::string m_inputContainer
void set(const HWIdentifier &chid, const int &gain, const int &bin)
std::string channel_name(const HWIdentifier id) const
Return a string corresponding to a feedthrough name given an identifier.
const LArHEC_Base_ID * m_hecId
bool is_lar_em(Identifier id) const
const LArFCAL_ID * fcal_idHelper() const
access to FCAL idHelper