|
ATLAS Offline Software
|
Go to the documentation of this file.
6 #include "GaudiKernel/MsgStream.h"
33 std::string strg =
"initialize_from_dictionary";
38 std::cout << strg << std::endl;
55 strg =
" initialize_from_dictionary - cannot access LArCalorimeter dictionary ";
60 std::cout <<
"LArOnline_SuperCellID::" << strg << std::endl;
76 log << MSG::INFO <<
"Finished initLevelsFromDict" <<
endmsg;
78 std::cout <<
"Finished initLevelsFromDict" << std::endl;
86 std::stringstream strm;
88 strg=
" Could not get value for label 'LArCalorimeter' of field 'subdet' in dictionary "+strm.str();
93 std::cout <<
"LArOnline_SuperCellID:" << strg << std::endl;
99 int larOnlineField = -4;
101 std::stringstream strm;
103 strg =
"Could not get value for label 'LArOnline' of field 'part' in dictionary "+strm.str();
108 std::cout << strg << std::endl;
114 int larOnlineCalibField = -5;
116 std::stringstream strm;
118 strg =
"Could not get value for label 'LArOnlineCalib' of field 'part' in dictionary "+strm.str();
123 std::cout << strg << std::endl;
139 std::string strg0=
" initialize_from_dictionary :";
141 std::string strg2=
" feedthrough slot range -> " + (std::string)
m_full_feb_range;
150 std::cout << strg0 << std::endl;
151 std::cout << strg1 << std::endl;
152 std::cout << strg2 << std::endl;
153 std::cout << strg3 << std::endl;
157 std::stringstream strm;
159 strg=
"[initialize_from_dictionary] version= " + strm.str();
164 std::cout <<
"LArOnline_SuperCellID: " << strg << std::endl;
191 int size = (1 << bits);
196 std::stringstream strm1;
197 std::stringstream strm2;
214 strg =
"Min > "+strm.str();
215 strg1=
" "+strm1.str();
216 strg2=
" "+strm2.str();
223 std::cout << strg << std::endl;
224 std::cout << strg1 << std::endl;
225 std::cout << strg2 << std::endl;
237 strg =
" ***** Error channel ranges, id, hash, i = "+strm.str();
238 strg1=
" , "+strm1.str();
239 strg2=
" , "+strm2.str();
246 std::cout << strg << std::endl;
247 std::cout << strg1 << std::endl;
248 std::cout << strg2 << std::endl;
300 std::cout <<
" ***** Warning cannot get ft expanded id for " <<
show_to_string(
min) << std::endl;
313 for (
unsigned int j = 0; j < nvalues; ++j) {
325 std::stringstream strm, strm1, strm2, strm3;
330 strg =
"Min > " + strm.str() +
" " + strm1.str() +
" " + strm2.str() +
" " + strm3.str();
335 std::cout << strg << std::endl;
344 std::stringstream strm, strm1, strm2;
348 strg =
" ***** Error feb ranges, id, hash, i = " +
349 strm.str() +
" , " + strm1.str() +
" , "+strm2.str();
354 std::cout << strg << std::endl;
365 int ft = feedthrough(
id);
366 return ( barrel_ec(
id)==1
368 (
ft==3 ||
ft==10 ||
ft==16 ||
ft==22 )
385 return (
bec==1 && sl==2 && sideCondition && (
ft==2 ||
ft==9 ||
400 (
ft == 0 ||
ft == 1 ||
ft == 2 ||
ft == 4 ||
ft == 5 ||
ft == 7 ||
ft == 8 ||
ft == 9 ||
ft == 11 ||
ft == 12 ||
ft == 13 ||
ft == 14 ||
ft == 15 ||
401 ft == 17 ||
ft == 18 ||
ft == 19 ||
ft == 20 ||
ft == 21 ||
ft == 23 ||
ft == 24)) ||
402 (sl==2 && sideCondition && (
ft==2 ||
ft==9 ||
ft==15 ||
ft==21))));
408 return (
bec == 1 && !(
ft==3 ||
ft==10 ||
ft==16 ||
ft==22 ||
ft==6));
MultiRange build_multirange() const
Get MultiRange for full dictionary.
bool isEMECOW(const HWIdentifier id) const override final
LArOnline_SuperCellID(void)
Default constructor.
IdentifierHash channel_Hash(HWIdentifier channelId) const
Create channel_hash from channel_Id.
virtual int initialize_from_dictionary(const IdDictMgr &dict_mgr) override
Initialization from the identifier dictionary.
~LArOnline_SuperCellID(void)
Default destructor.
std::vector< int > m_slot_values
bool isEMECIW(const HWIdentifier id) const override final
IdDictFieldImplementation m_feedthrough_impl
int slot(const HWIdentifier id) const
Return the slot number of a hardware cell identifier: slot = [1,15] Slot-ID in top part of the crat...
IdDictFieldImplementation m_slot_impl
Define the Hash identifier for channels and febs.
IMessageSvc * m_msgSvc
pointer to the message service
IdContext feedthroughContext(void) const
Define context for feedthroughs.
const IdDictDictionary * m_dict
IdDictFieldImplementation m_side_impl
int barrel_ec(const HWIdentifier id) const
Return the position barrel or endcap of a hardware cell identifier: barrel_ec = [0,...
int unpack(Identifier id) const
Identifier manipulation methods.
size_type m_feedthroughHashMax
virtual std::string dictionaryVersion(void) const override
IdDictFieldImplementation m_bec_slot_impl
std::vector< HashCalcFeb > m_feb_hash_calcs
MultiRange m_full_feedthrough_range
bool isHECchannel(const HWIdentifier id) const override final
int channel(const HWIdentifier id) const
Return the channel number of a hardware cell identifier channel = [0,127] in all FEB.
IdDictDictionary * find_dictionary(const std::string &name) const
Access dictionary by name.
void set_bits(size_type bits, size_type bits_offset)
bool isEMECchannel(const HWIdentifier id) const override final
int get_expanded_id(const HWIdentifier &id, ExpandedIdentifier &exp_id, const IdContext *context) const
create expanded HWIdentifier from HWIdentifier (return == 0 for OK)
size_type bits_offset() const
HWIdentifier channel_Id(int barrel_ec, int pos_neg, int feedthrough, int slot, int channel) const
create channel identifier from fields
int pos_neg(const HWIdentifier id) const
Return the side of a hardware cell identifier pos_neg = [0,1] positive-side or negative-side Barrel...
int initLevelsFromDict(const std::string &group_name)
size_type m_channelHashMax
bool isEnumerated() const
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
IdentifierHash channel_Hash_binary_search(HWIdentifier channelId) const
int register_dict_tag(const IdDictMgr &dict_mgr, const std::string &dict_name)
Register the file and tag names for a particular IdDict dictionary.
int get_label_value(const std::string &field, const std::string &label, int &value) const
int initialize_from_dictionary(const IdDictMgr &dict_mgr) override final
initialization from the identifier dictionary
Helper for the Liquid Argon Calorimeter cell identifiers.
IdentifierHash feb_Hash_binary_search(HWIdentifier channelId) const
virtual void setDictVersion(const IdDictMgr &dict_mgr, const std::string &name) override
A Range describes the possible ranges for the field values of an ExpandedIdentifier.
std::vector< HashCalc > m_chan_hash_calcs
IdDictFieldImplementation m_bec_impl
int feedthrough(const HWIdentifier id) const
Return the feedthrough of a hardware cell identifier : feedthrough = [0,31] Barrel - A/C side or H/...
bool reinitialize(const IdDictMgr &dict_mgr)
Test whether an idhelper should be reinitialized based on the change of tags.
MultiRange m_full_feb_range
std::string show_to_string(Identifier id, const IdContext *context=0, char sep='.') const
or provide the printout in string form
MultiRange m_full_laronline_range
This is the individual specification for the range of one ExpandedIdentifier IdentifierField.
element_type get_value_at(size_type index) const
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
This class saves the "context" of an expanded identifier (ExpandedIdentifier) for compact or hash ver...
IdDictFieldImplementation m_bec_ft_impl
size_type get_indices() const
IdentifierHash feb_Hash(HWIdentifier febId) const
Create feb hash identifiers from feb identifiers.
bool match(std::string s1, std::string s2)
match the individual directories of two strings
HWIdentifier feedthrough_Id(int barrel_ec, int pos_neg, int feedthrough) const
Create a feedthrough identifier from fields.
Identifier::size_type size_type