From 2da19207de4c5e4b3cf9fb0eef17da8ddcd9680c Mon Sep 17 00:00:00 2001 From: Lanchid Date: Wed, 19 Dec 2012 18:25:32 +0100 Subject: [PATCH] Removed check for valid probablilities, as we want to use the DeterministicSparseTransitionParser for CTMCs (which have edges that are not labeled with probabilities, but with weights) later on --- src/parser/DeterministicSparseTransitionParser.cpp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/parser/DeterministicSparseTransitionParser.cpp b/src/parser/DeterministicSparseTransitionParser.cpp index 636d43655..d62661521 100644 --- a/src/parser/DeterministicSparseTransitionParser.cpp +++ b/src/parser/DeterministicSparseTransitionParser.cpp @@ -82,7 +82,7 @@ uint_fast64_t DeterministicSparseTransitionParser::firstPass(char* buf, uint_fas if (col > maxnode) maxnode = col; /* * read value. if value is 0.0, either strtod could not read a number or we encountered a probability of zero. - * if row == col, we have a diagonal element which is treated seperately and this non_zero must be decreased. + * if row == col, we have a diagonal element which is treated separately and this non_zero must be decreased. */ val = strtod(buf, &tmp); if (val == 0.0) { @@ -178,14 +178,6 @@ DeterministicSparseTransitionParser::DeterministicSparseTransitionParser(const c col = checked_strtol(buf, &buf); val = strtod(buf, &buf); - /* - * only values in (0, 1] are meaningful - */ - if ((val <= 0.0) || (val > 1.0)) - { - LOG4CPLUS_ERROR(logger, "Found transition probability of " << val << ", but we think probabilities should be from (0,1]."); - throw mrmc::exceptions::WrongFileFormatException(); - } this->matrix->addNextValue(row,col,val); buf = skipWS(buf); }