I'm trying to get a deeper understanding of the class_weight parameter in sci-kit learn. How exactly does the class_weight penalize errors for certain classes? Is it weighting errors in the loss function?
Asked
Active
Viewed 50 times
0
-
This depends on a particular model, not scikit-learn. – lejlot May 26 '17 at 19:49
-
1As a particular example for trees, [see my answer here](https://stackoverflow.com/questions/34389624/what-does-sample-weight-do-to-the-way-a-decisiontreeclassifier-works-in-skle/34477381#34477381). – Matt Hancock May 28 '17 at 11:11
-
Nice example. Thanks – Matthew Tichenor May 30 '17 at 18:06