Added cast to float to remove warning

pull/5616/head^2
Abe Friesen 9 years ago
parent db78fcd11a
commit d367e159c1
  1. 2
      modules/ml/src/lr.cpp

@ -303,7 +303,7 @@ float LogisticRegressionImpl::predict(InputArray samples, OutputArray results, i
}
}
return ( pred_labs.empty() ? 0 : pred_labs.at< int >( 0 ) );
return ( pred_labs.empty() ? 0.f : (float) pred_labs.at< int >( 0 ) );
}
Mat LogisticRegressionImpl::calc_sigmoid(const Mat& data) const

Loading…
Cancel
Save