47 return StatusCode::SUCCESS;
58 return StatusCode::SUCCESS;
68 return StatusCode::FAILURE;
79 typedef std::vector<Identifier>::const_iterator It;
82 for (; beg != end; ++beg) {
85 if (!
id.is_valid())
continue;
95 std::sprintf(name,
"shap%.9d_%.1d%.1d%.1d%.1d%.3d%.3d",
105 unsigned sz1 = shape.size();
106 unsigned sz2 = shapeder.size();
107 TH1* h1 =
new TH1F (name, name, sz1 + sz2, 0, sz1 + sz2);
110 for (
unsigned int i=0; i < sz1; i++)
111 h1->SetBinContent (i+1, shape[i]);
112 for (
unsigned int i=0; i < sz2; i++) {
113 double der = shapeder[i];
116 if (std::abs(der) > 1e10) der = 1e10;
117 h1->SetBinContent (i+sz1+1, der);
128 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
Helpers for checking error return status codes and reporting errors.
#define CHECK(...)
Evaluate an expression and check for errors.
Dump out shape information to a ROOT file.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
const ServiceHandle< StoreGateSvc > & detStore() const
Helper class for offline cell identifiers.
const LArEM_ID * em_idHelper() const
access to EM idHelper
LArVectorProxy ShapeRef_t
This class defines the interface for accessing Shape (Nsample variable, Dt = 25 ns fixed) @stereotype...
virtual ShapeRef_t Shape(const HWIdentifier &id, int gain, int tbin=0, int mode=0) const =0
virtual ShapeRef_t ShapeDer(const HWIdentifier &id, int gain, int tbin=0, int mode=0) const =0
value_type get_compact() const
Get the compact id.
bool is_valid() const
Check if id is in a valid state.
Identifier32 get_identifier32() const
Get the 32-bit version Identifier, will be invalid if >32 bits needed.
StatusCode execute()
Standard Gaudi execute method.
std::string m_filename
JO property: The nmae of the ROOT file to create.
LArDumpShapes(const std::string &name, ISvcLocator *svcloc)
Standard Algorithm constructor.
bool m_first
True for the first event.
SG::ReadCondHandleKey< LArOnOffIdMapping > m_cablingKey
int m_gain
JO property: The desired gain.
StatusCode initialize()
Standard algorithm methods.
int region(const Identifier id) const
return region according to :
int eta(const Identifier id) const
return eta according to :
int phi(const Identifier id) const
return phi according to :
id_iterator em_begin() const
begin iterator over full set of EM Identifiers
int barrel_ec(const Identifier id) const
return barrel_ec according to :
int sampling(const Identifier id) const
return sampling according to :
id_iterator em_end() const
end iterator over full set of EM Identifiers
Helper class for LArEM offline identifiers.