36 std::vector<double> parVecVec(functionPtr->parameters());
37 std::vector<double>::const_iterator parVec = parVecVec.begin();
38 std::vector<int> functionId(functionPtr->identifiers());
39 std::vector<int>::const_iterator
id = functionId.begin();
40 edm::LogPrint(
"DBReader") <<
"total number of parameters read from database = parVecVec.size() = " 41 << parVecVec.size() << std::endl;
43 for (;
id != functionId.end(); ++
id, ++iFunc) {
44 int parNum = functionPtr->function(iFunc)->parNum();
45 edm::LogPrint(
"DBReader") <<
"For function id = " << *
id <<
", with " << parNum <<
" parameters: " << std::endl;
46 for (
int par = 0; par < parNum; ++par) {
47 edm::LogPrint(
"DBReader") <<
"par[" << par <<
"] = " << *parVec << std::endl;
67 edm::LogInfo(
"DBReader") <<
"[DBReader::analyze] End Reading MuScleFitDBobjectRcd" << std::endl;
75 else if (
type_ ==
"resolution")
77 else if (
type_ ==
"background")
80 edm::LogPrint(
"DBReader") <<
"Error: unrecognized type. Use one of those: 'scale', 'resolution', 'background'" 95 else if (
type_ ==
"resolution")
97 else if (
type_ ==
"background")
std::shared_ptr< MomentumScaleCorrector > corrector_
std::shared_ptr< BackgroundFunction > background_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
void analyze(const edm::Event &, const edm::EventSetup &) override
void initialize(const edm::EventSetup &iSetup)
const edm::ESGetToken< MuScleFitDBobject, MuScleFitDBobjectRcd > muToken_
std::vector< int > identifiers
DBReader(const edm::ParameterSet &)
#define DEFINE_FWK_MODULE(type)
Log< level::Warning, true > LogPrint
void printParameters(const T &functionPtr)
std::shared_ptr< ResolutionFunction > resolution_
Log< level::Info, false > LogInfo
std::vector< double > parameters