do not print failure data even in debug compilation
This commit is contained in:
parent
5310bba7fc
commit
556a1fe572
1 changed files with 2 additions and 2 deletions
4
test.cpp
4
test.cpp
|
|
@ -163,14 +163,12 @@ void test( unsigned int M, unsigned int N, unsigned int F, unsigned int R, unsig
|
||||||
// a variance-covariance matrix of size N*N
|
// a variance-covariance matrix of size N*N
|
||||||
CovarMat V = ublas::prod( ublas::trans(S), S );
|
CovarMat V = ublas::prod( ublas::trans(S), S );
|
||||||
assert( V.size1() == N && V.size2() == N );
|
assert( V.size1() == N && V.size2() == N );
|
||||||
|
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
if( R == 1 ) {
|
if( R == 1 ) {
|
||||||
std::cout << std::endl << "Covariance matrix:" << std::endl;
|
std::cout << std::endl << "Covariance matrix:" << std::endl;
|
||||||
std::cout << format(V) << std::endl;
|
std::cout << format(V) << std::endl;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
for( typename AlgoMap::iterator ialgo = algos.begin(); ialgo != algos.end(); ++ialgo ) {
|
for( typename AlgoMap::iterator ialgo = algos.begin(); ialgo != algos.end(); ++ialgo ) {
|
||||||
// The LLT algorithm can fail on a sqrt(x<0) and throw an error
|
// The LLT algorithm can fail on a sqrt(x<0) and throw an error
|
||||||
// we thus count the failures
|
// we thus count the failures
|
||||||
|
|
@ -182,9 +180,11 @@ void test( unsigned int M, unsigned int N, unsigned int F, unsigned int R, unsig
|
||||||
|
|
||||||
} catch( cholesky::NotDefinitePositive & error ) {
|
} catch( cholesky::NotDefinitePositive & error ) {
|
||||||
fails[ialgo->first]++;
|
fails[ialgo->first]++;
|
||||||
|
/*
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
std::cout << "FAILED:\t" << error.what() << std::endl;
|
std::cout << "FAILED:\t" << error.what() << std::endl;
|
||||||
#endif
|
#endif
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
|
|
||||||
} // for ialgo in algos
|
} // for ialgo in algos
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue