34 for(
auto const& itr : parNames){
43 fixed = param.
get<
bool >(
"Fixed", true );
44 val = param.
get<
double >(
"Value", 0. );
45 nuisance = param.
get<
bool >(
"Nuisance", false );
46 sigma = param.
get<
float >(
"Sigma", 1.e6 );
47 centralVal = param.
get<
float >(
"CentralValue", 0. );
48 variance = param.
get<
float >(
"Variance", 1.e-5 );
49 constraint = param.
get<
bool >(
"Constraint", false );
50 lowerBound = param.
get<
float >(
"LoVal", 0. );
51 upperBound = param.
get<
float >(
"HiVal", 1.e6 );
54 if(parstr.find(
"Wgt") != std::string::npos) parstr.erase(parstr.find(
"Wgt"), 3);
70 <<
"inserting parameter " 76 <<
" full location is " 85 if(gParUtil ==
nullptr)
101 std::vector<std::string> psetNames({
"OscillationParameters",
102 "SystematicParameters"});
105 for(
auto const& detItr : dets){
106 for(
auto const& nameItr : psetNames){
110 if(nameItr.find(
"Oscillation") != std::string::npos)
112 else if(nameItr.find(
"Systematic") != std::string::npos)
119 <<
"\n-------------------------------------------------------" 120 <<
"\nPARAMETER SUMMARY" 121 <<
"\n-------------------------------------------------------";
125 <<
"\n=======================================================\n" 127 <<
"\n=======================================================" 128 <<
"\n\nRunning with systematic parameters set to \n";
130 for(
auto const& parItr : itr.Parameters()){
144 <<
"\nRunning with oscillation parameters set to \n";
146 if(odItr.Detector() != itr.Detector())
continue;
147 for(
auto const& oscItr : odItr.Parameters()){
170 if(dopItr.Detector() !=
det)
continue;
172 if(dopItr.count(parName) < 1)
174 <<
"oscillation parameter " 176 <<
" is not in the list for the " 180 return dopItr.Parameter(parName);
184 return fDetOscParameters.front().Parameter(parName);
193 if(dspItr.count(parName) < 1)
195 <<
"systematic parameter " 197 <<
" is not in the list";
199 return dspItr.Parameter(parName);
203 return fDetSysParameters.front().Parameter(parName);
223 if(dspItr.count(parName) > 0 )
return true;
235 std::vector<cmf::ParameterSpaceLoc> pslVec;
238 std::vector<cmf::Parameter> detPars;
240 for(
auto const& oscParItr : itr.Parameters()){
241 detPars.emplace_back(oscParItr);
245 if(sysDetItr.Detector() == itr.Detector()){
246 for(
auto const& sysParItr : sysDetItr.Parameters()){
247 detPars.emplace_back(sysParItr);
252 pslVec.emplace_back(itr.Detector(), detPars);
257 return std::move(loc);
263 std::set<std::string> parNames;
265 for(
auto const& parItr : itr.Parameters())
266 parNames.emplace(parItr.Name());
269 return std::move(parNames);
275 std::set<uint8_t> parKeys;
277 for(
auto const& parItr : itr.Parameters())
278 parKeys.emplace(parItr.Key());
281 return std::move(parKeys);
288 if(itr.Detector() ==
det)
return itr.Parameters();
293 std::vector<cmf::Parameter> emptyParVec;
294 return std::move(emptyParVec);
std::vector< cmf::ParameterSpaceLoc > fDetOscParameters
values for the oscillation parameters in each detector
std::vector< cmf::Parameter > const & Parameters() const
void Initialize(fhicl::ParameterSet const &pset)
std::set< std::string > SysParNames() const
const std::vector< std::string > cDetType_Strings({"UnknownDet","NearDet","FarDet","MINOSNear","MINOSFar","AllDetectors"})
cmf::Parameter const & OscParameterInfo(std::string const &parName, cmf::DetType_t const &det=cmf::kFARDET) const
cmf::Parameter const & ParameterInfo(std::string const &parName) const
static SelectionUtility * Instance()
std::set< uint8_t > SysParKeys() const
enum cmf::det_type DetType_t
::xsd::cxx::tree::exception< char > exception
std::vector< cmf::ParameterSpaceLoc > fDetSysParameters
values for the systematic parameters in each detector
std::vector< cmf::Parameter > const & SysParameters(cmf::DetType_t const &det=cmf::kFARDET) const
static ParameterUtility * Instance()
bool UseSysPar(std::string const &parName)
T get(std::string const &key) const
static cmf::DetType_t StringToDetectorType(std::string const &str)
void InsertParameter(cmf::Parameter const &par)
static ParameterUtility * gParUtil
std::vector< std::string > get_names() const
static bool IsOscillationParameter(std::string const &str)
Module to combine a set of results into a single file currently only does one data product type at a ...
void ParameterSetToLocation(fhicl::ParameterSet const &pset, cmf::DetType_t const &det, cmf::Location &loc)
std::set< cmf::DetType_t > const & DetectorsToUse()
std::string to_indented_string() const
#define MF_LOG_VERBATIM(category)
cmf::Location ParametersAsLocation()
cmf::ParameterSpaceLoc const & DetectorLocation(cmf::DetType_t const &det) const
cmf::Parameter const & SysParameterInfo(std::string const &parName) const