title: How to use downsampling and configure class weight parameter when using XGboost for imbalanced classification?
body: <p>I am working on binary classification problem on a  dataset with extreme class imbalance. To help the model learn the signals of the minority class, I downsampled the majority class such that the training set has  20% of minority class and 80% majority class.</p>
  <p>Now there is one other parameter &quot;scale_pos_weight&quot; . I am not sure how to set this parameter after downsampling.</p>
  <p>Should i set this based on the actual class ratios or should i use the class ratios after downsampling?</p>