aksnzhy / xlearn

High performance, easy-to-use, and scalable machine learning (ML) package, including linear model (LR), factorization machines (FM), and field-aware factorization machines (FFM) for Python and CLI interface.
https://xlearn-doc.readthedocs.io/en/latest/index.html
Apache License 2.0
3.09k stars 518 forks source link

How to set class weight for target label. #146

Open sandiemann opened 6 years ago

sandiemann commented 6 years ago

Hello,

I am dealing with highly imbalance data and I was wondering if there is an option to set the class weight for the target labels for FFM model training to basically under-sample the negative class.

Regards, Sanchit

popeye007 commented 6 years ago

I have the same problem for FM model. Is is possible to tweak the source code for setting class weight for the minority class?

aksnzhy commented 6 years ago

@sandiemann @popeye007 I will add this feature to xLearn in the next version. Thanks so much!

thestick613 commented 4 years ago

@aksnzhy any updates on this? Is it documented? Thank you.