From e5763e7ec8c1734cf11fe29d743d0332df57c1b9 Mon Sep 17 00:00:00 2001 From: getumen Date: Fri, 2 Aug 2024 16:26:01 +0900 Subject: [PATCH] fix bug in fil.go (#50) --- go/fil.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/go/fil.go b/go/fil.go index 49fadfe..ae2ea5a 100644 --- a/go/fil.go +++ b/go/fil.go @@ -152,7 +152,7 @@ func (m *FILModel) PredictSingleClassScore( result := make([]float32, numRow) for i := 0; i < numRow; i++ { - result[i] = resultRaw[i*m.NumClass()+1] + result[i] = resultRaw[i*2+1] } return result, nil } @@ -165,6 +165,3 @@ func (m *FILModel) Close() error { return err } -func (m *FILModel) NumClass() int { - return m.raw.NumClass() -}