27 nbinsX(ps.getUntrackedParameter<unsigned
int>(
"nbinsX", 0)),
28 nbinsY(ps.getUntrackedParameter<unsigned
int>(
"nbinsY", 0)),
29 xmin(ps.getUntrackedParameter<double>(
"xmin", 0)),
30 xmax(ps.getUntrackedParameter<double>(
"xmax", 0)),
31 ymin(ps.getUntrackedParameter<double>(
"ymin", 0)),
32 ymax(ps.getUntrackedParameter<double>(
"ymax", 0)),
33 binsXtmp(ps.getUntrackedParameter<vdouble>(
"binsX", vdouble())),
34 binsYtmp(ps.getUntrackedParameter<vdouble>(
"binsY", vdouble())),
46 const std::map<std::string, unsigned int> &
mapping) {
49 std::vector<unsigned int> map_values;
51 for (
auto const &imap : mapping) {
52 map_values.push_back(imap.second);
54 unsigned int max_size = *std::max_element(map_values.begin(), map_values.end());
55 max_size =
std::max(max_size, (
unsigned int) mapping.size());
56 definitions.resize(max_size);
58 for (
auto name : names) {
59 if (mapping.find(
name) != mapping.end()) {
64 <<
"Could not find histogram definition for '" <<
name <<
"'" std::vector< float > binsX
std::vector< double > binsYtmp
T getParameter(std::string const &) const
static const HistoName names[]
std::vector< HistDefinition > HistDefinitions
std::vector< std::string > getParameterNames() const
std::vector< double > vdouble
HistDefinitions readHistDefinitions(const edm::ParameterSet &ps, const std::map< std::string, unsigned int > &mapping)
std::vector< float > binsY
std::vector< double > binsXtmp