10 std::ifstream parametersFile(fileName.Data());
12 if( !parametersFile.is_open() ) {
13 std::cout <<
"Error: file " << fileName <<
" not found. Aborting." << std::endl;
20 while (parametersFile) {
21 getline( parametersFile, line );
22 size_t lineInt = line.find(
"value");
25 size_t iterationSubStr = line.find(iteration);
28 if( iterationSubStr != std::string::npos ) {
30 int scaleFunctionNum = 0;
34 std::stringstream sLine(line);
38 while( sLine >> num ) {
41 if( wordCounter == 9 ) {
42 std::stringstream
in(num);
43 in >> scaleFunctionNum;
45 if( wordCounter == 13 ) {
46 std::stringstream
in(num);
65 if ( (lineInt != std::string::npos) ) {
66 size_t subStr1 = line.find(
"value");
67 std::stringstream paramStr;
71 paramStr << line.substr(subStr1+5);
scaleFunctionBase< double * > * scaleFunctionService(const int identifier)
Service to build the scale functor corresponding to the passed identifier.
std::vector< double > parVecVec_
void convertToArrays(T **&function_, const std::vector< T * > &functionVec_)
Convert vectors to arrays for faster random access. The first pointer is replaced, thus it is taken by reference.
scaleFunctionBase< double * > ** scaleFunction_
void readParameters(TString fileName)
Parser of the parameters file.
std::vector< int > functionId_
std::vector< scaleFunctionBase< double * > * > scaleFunctionVec_