#include <METCorrectorParameters.h>
|
template<class Archive > |
void | serialize (Archive &ar, const unsigned int version) |
| is this a valid set? More...
|
|
Definition at line 14 of file METCorrectorParameters.h.
METCorrectorParameters::METCorrectorParameters |
( |
| ) |
|
|
inline |
METCorrectorParameters::METCorrectorParameters |
( |
const std::string & |
fFile, |
|
|
const std::string & |
fSection = "" |
|
) |
| |
Definition at line 111 of file METCorrectorParameters.cc.
References trackerTree::check(), definitions(), METCorrectorParameters::Definitions::formula(), insertMaterial::getSection(), i, input, geometryCSVtoXML::line, mDefinitions, mRecords, METCorrectorParameters::Definitions::nBinVar(), METCorrectorParameters::Record::nParameters(), record(), AlCaHLTBitMon_QueryRunRegistry::string, tmp, valid_, METCorrectorParameters::Record::xMax(), and METCorrectorParameters::Record::xMin().
113 std::ifstream
input(fFile.c_str());
117 while (std::getline(
input,line))
122 if (!section.empty() && tmp.empty())
124 currentSection = section;
127 if (currentSection == fSection)
131 currentDefinitions =
tmp;
148 if (currentDefinitions==
"")
149 handleError(
"METCorrectorParameters",
"No definitions found!!!");
151 if (
mRecords.empty() && currentSection !=
"")
153 std::stringstream sserr;
154 sserr<<
"the requested section "<<fSection<<
" doesn't exist!";
155 handleError(
"METCorrectorParameters",sserr.str());
unsigned nParameters() const
const Record & record(unsigned fBin) const
std::vector< METCorrectorParameters::Record > mRecords
static std::string const input
const Definitions & definitions() const
float xMax(unsigned fVar) const
METCorrectorParameters::Definitions mDefinitions
float xMin(unsigned fVar) const
std::string formula() const
std::vector< std::vector< double > > tmp
Definition at line 75 of file METCorrectorParameters.h.
References valid_.
std::vector< METCorrectorParameters::Record > mRecords
METCorrectorParameters::Definitions mDefinitions
std::vector<float> METCorrectorParameters::binCenters |
( |
unsigned |
fVar | ) |
const |
int METCorrectorParameters::binIndex |
( |
const std::vector< float > & |
fX | ) |
const |
const Definitions& METCorrectorParameters::definitions |
( |
| ) |
const |
|
inline |
bool METCorrectorParameters::isValid |
( |
void |
| ) |
const |
|
inline |
int METCorrectorParameters::neighbourBin |
( |
unsigned |
fIndex, |
|
|
unsigned |
fVar, |
|
|
bool |
fNext |
|
) |
| const |
void METCorrectorParameters::printFile |
( |
const std::string & |
fFileName | ) |
const |
Definition at line 306 of file METCorrectorParameters.cc.
References METCorrectorParameters::Definitions::binVar(), definitions(), EcalElecEmulTccOnlyExample_cfg::formula, METCorrectorParameters::Definitions::formula(), i, j, METCorrectorParameters::Definitions::nBinVar(), METCorrectorParameters::Record::nParameters(), METCorrectorParameters::Definitions::nParVar(), METCorrectorParameters::Record::parameter(), METCorrectorParameters::Definitions::parVar(), record(), size(), METCorrectorParameters::Record::xMax(), and METCorrectorParameters::Record::xMin().
308 std::ofstream txtFile;
309 txtFile.open(fFileName.c_str());
310 txtFile.setf(std::ios::right);
unsigned nParameters() const
std::vector< std::string > parVar() const
const Record & record(unsigned fBin) const
const Definitions & definitions() const
float xMax(unsigned fVar) const
std::vector< std::string > binVar() const
float xMin(unsigned fVar) const
std::string formula() const
float parameter(unsigned fIndex) const
void METCorrectorParameters::printScreen |
( |
| ) |
const |
Definition at line 273 of file METCorrectorParameters.cc.
References METCorrectorParameters::Definitions::binVar(), gather_cfg::cout, definitions(), METCorrectorParameters::Definitions::formula(), i, j, METCorrectorParameters::Definitions::nBinVar(), METCorrectorParameters::Record::nParameters(), METCorrectorParameters::Definitions::nParVar(), METCorrectorParameters::Record::parameter(), METCorrectorParameters::Definitions::parVar(), record(), size(), METCorrectorParameters::Record::xMax(), and METCorrectorParameters::Record::xMin().
275 std::cout<<
"--------------------------------------------"<<std::endl;
276 std::cout<<
"//////// PARAMETERS: //////////////////////"<<std::endl;
277 std::cout<<
"--------------------------------------------"<<std::endl;
279 std::cout<<
"Names of binning variables: ";
283 std::cout<<
"--------------------------------------------"<<std::endl;
285 std::cout<<
"Names of parameter variables: ";
289 std::cout<<
"--------------------------------------------"<<std::endl;
291 std::cout<<
"--------------------------------------------"<<std::endl;
292 std::cout<<
"------- Bin contents -----------------------"<<std::endl;
unsigned nParameters() const
std::vector< std::string > parVar() const
const Record & record(unsigned fBin) const
const Definitions & definitions() const
float xMax(unsigned fVar) const
std::vector< std::string > binVar() const
float xMin(unsigned fVar) const
std::string formula() const
float parameter(unsigned fIndex) const
const Record& METCorrectorParameters::record |
( |
unsigned |
fBin | ) |
const |
|
inline |
template<class Archive >
void METCorrectorParameters::serialize |
( |
Archive & |
ar, |
|
|
const unsigned int |
version |
|
) |
| |
|
private |
unsigned METCorrectorParameters::size |
( |
void |
| ) |
const |
|
inline |
unsigned METCorrectorParameters::size |
( |
unsigned |
fVar | ) |
const |
friend class boost::serialization::access |
|
friend |
template<typename CondSerializationT , typename Enabled >
bool METCorrectorParameters::valid_ |
|
private |