From 8b872571037bf25619a8900782aad0a470fee1cc Mon Sep 17 00:00:00 2001 From: Davis King Date: Wed, 9 Nov 2016 10:30:16 -0500 Subject: [PATCH] Fixed rls numerical instability. --- dlib/svm/rls.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlib/svm/rls.h b/dlib/svm/rls.h index 2c46d611f..edee6b062 100644 --- a/dlib/svm/rls.h +++ b/dlib/svm/rls.h @@ -102,7 +102,7 @@ namespace dlib add_eye_to_inv(R, (1-forget_factor)/C); // R should always be symmetric. This line improves numeric stability of this algorithm. - if (cnt%100 == 0) + if (cnt%10 == 0) R = 0.5*(R + trans(R)); ++cnt;