diff --git a/CMakeLists.txt b/CMakeLists.txt index 1f287bd879d6f2a4c558bbf5edd6c1e93db01450..ac723eaf06f90191559b68b5d3f0b1f088240ff7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -55,8 +55,8 @@ ADD_DEFINITIONS( #----------------------------------------------------------------------------- # OTB version number. An even minor number corresponds to releases. -SET(OTB_VERSION_MAJOR "1") -SET(OTB_VERSION_MINOR "6") +SET(OTB_VERSION_MAJOR "2") +SET(OTB_VERSION_MINOR "0") SET(OTB_VERSION_PATCH "0") # Version string should not include patch level. The major.minor is diff --git a/Code/Radiometry/otbReflectanceToSurfaceReflectanceImageFilter.h b/Code/Radiometry/otbReflectanceToSurfaceReflectanceImageFilter.h index 55acd70896661c5d757cc5fb67941ba09a314ece..77567896327ef0a2432cabe2e18acbf5246c4034 100644 --- a/Code/Radiometry/otbReflectanceToSurfaceReflectanceImageFilter.h +++ b/Code/Radiometry/otbReflectanceToSurfaceReflectanceImageFilter.h @@ -71,7 +71,7 @@ namespace otb TOutput outPixel; double temp, temp2; temp = static_cast<double>(inPixel)*m_Coefficient + m_Residu; - temp2 = temp / (1 + m_SphericalAlbedo * temp); + temp2 = temp / (1. + m_SphericalAlbedo * temp); outPixel = static_cast<TOutput>(temp2); @@ -165,7 +165,7 @@ namespace otb coef = static_cast<double>(m_AtmosphericRadiativeTerms->GetTotalGaseousTransmission(i) * m_AtmosphericRadiativeTerms->GetDownwardTransmittance(i) * m_AtmosphericRadiativeTerms->GetUpwardTransmittance(i) ); - coef = 1 / coef; + coef = 1. / coef; res = -m_AtmosphericRadiativeTerms->GetIntrinsicAtmosphericReflectance(i) * coef; FunctorType functor; diff --git a/Testing/Code/Learning/CMakeLists.txt b/Testing/Code/Learning/CMakeLists.txt index 68c1e7bc946ce94acb05c2d5d901eca35295c45b..c9c2fa5c491160517df5e932d25011385f3d78e6 100644 --- a/Testing/Code/Learning/CMakeLists.txt +++ b/Testing/Code/Learning/CMakeLists.txt @@ -16,8 +16,8 @@ SET(LEARNING_TESTS ${CXX_TEST_PATH}/otbLearningTests) #EPSILON est different de 0.0 pour les tests multiplateformes avec différentes options de compilation. SET(EPSILON 0.0000000001) -SET(BIGEPSILON 0.001) - +SET(EPSILON_10e3 0.001) +SET(EPSILON_10e4 0.0001) # ------- otb::SVMModel ------------------------------ @@ -75,7 +75,7 @@ ADD_TEST(leTuSVMImageModelEstimatorNew ${LEARNING_TESTS} otbSVMImageModelEstimatorNew) ADD_TEST(leTvSVMImageModelEstimatorTrain ${LEARNING_TESTS} ---compare-ascii ${BIGEPSILON} ${BASELINE_FILES}/leTvsvm_model_image +--compare-ascii ${EPSILON_10e3} ${BASELINE_FILES}/leTvsvm_model_image ${TEMP}/leTvsvm_model_image otbSVMImageModelEstimatorTrain ${INPUTDATA}/ROI_QB_MUL_4.tif @@ -83,7 +83,7 @@ ADD_TEST(leTvSVMImageModelEstimatorTrain ${LEARNING_TESTS} ${TEMP}/leTvsvm_model_image) ADD_TEST(leTvSVMImageModelEstimatorModelAccessor ${LEARNING_TESTS} ---compare-ascii ${TOL} ${BASELINE_FILES}/leSVMModelEstimatorModelAccessor.txt +--compare-ascii ${EPSILON_10e4} ${BASELINE_FILES}/leSVMModelEstimatorModelAccessor.txt ${TEMP}/leSVMModelEstimatorModelAccessor.txt otbSVMImageModelEstimatorModelAccessor ${INPUTDATA}/ROI_QB_MUL_4.tif @@ -96,7 +96,7 @@ ADD_TEST(leTuSVMPointSetModelEstimatorNew ${LEARNING_TESTS} otbSVMPointSetModelEstimatorNew) ADD_TEST(leTuSVMPointSetModelEstimatorTrain ${LEARNING_TESTS} ---compare-ascii ${BIGEPSILON} ${BASELINE_FILES}/leTvsvm_model_pointset +--compare-ascii ${EPSILON_10e3} ${BASELINE_FILES}/leTvsvm_model_pointset ${TEMP}/leTvsvm_model_pointset otbSVMPointSetModelEstimatorTrain ${TEMP}/leTvsvm_model_pointset) diff --git a/Testing/Code/Learning/otbSVMImageModelEstimatorModelAccessor.cxx b/Testing/Code/Learning/otbSVMImageModelEstimatorModelAccessor.cxx index ef8ae75cf4e829e70cfce91cdcebee1c0836a51b..42e54e8a63992a3e121084137150b147001fbbbb 100644 --- a/Testing/Code/Learning/otbSVMImageModelEstimatorModelAccessor.cxx +++ b/Testing/Code/Learning/otbSVMImageModelEstimatorModelAccessor.cxx @@ -126,7 +126,7 @@ int otbSVMImageModelEstimatorModelAccessor( int argc, char* argv[] ) { itkGenericExceptionMacro(<<"rhos NULL"); } - f << " "; + f << std::setprecision(10) <<" "; for(unsigned int i=0;i<taille;i++) { f << " " << rhos[i];