svmsgd.cpp, fix #6248

add a cast to double, to make vs compilers happy
This commit is contained in:
berak 2016-03-14 08:02:09 +01:00
parent fbc221d334
commit 4555f9ac25

View File

@ -153,7 +153,7 @@ void SVMSGDImpl::normalizeSamples(Mat &samples, Mat &average, float &multiplier)
double normValue = norm(samples);
multiplier = static_cast<float>(sqrt(samples.total()) / normValue);
multiplier = static_cast<float>(sqrt(static_cast<double>(samples.total())) / normValue);
samples *= multiplier;
}