Imbalance in scikit-learn

前端 未结 5 544
北恋
北恋 2021-01-31 08:35

I\'m using scikit-learn in my Python program in order to perform some machine-learning operations. The problem is that my data-set has severe imbalance issues.

Is anyone

5条回答
  •  鱼传尺愫
    2021-01-31 08:58

    In Scikit learn there are some imbalance correction techniques, which vary according with which learning algorithm are you using.

    Some one of them, like Svm or logistic regression, have the class_weight parameter. If you instantiate an SVC with this parameter set on 'auto', it will weight each class example proportionally to the inverse of its frequency.

    Unfortunately, there isn't a preprocessor tool with this purpose.

提交回复
热议问题