Opencv3.0 LogisticRegression svm scaling
I am trying to use cv::ml::LogisticRegression
to scale the weights given by a SVM.
To train the model I am passing the weight data in the range of [-inf, inf] and the labels (-1 or 1) to the function cv::ml::LogisticRegression::train()
Till now everything works fine, but when I try to predict a sample by using cv::ml::LogisticRegression::predict()
I allways get the result -1 or 1. Thus exactly the same result as from the SVM. In my opinion the result should be a probability between 0 and 1.
Used parameters for cv::ml::LogisticRegression()
:
- learning rate: 0.001
- iterations: 1000
- train method: BATCH
- regularisation: REG_L2
- minibatch_size: 1
Am I doing anythin wrong ?