liveBook · Manning

Cost-sensitive learning

As explained in Build AI Drug Discovery Pipelines

Cost-sensitive learning incorporates unequal costs for different prediction errors into model training.

Cost-sensitive learning modifies model loss so different prediction errors receive different penalties. In virtual screening, a false negative may waste downstream drug-discovery resources, making error costs part of the modeling problem. section 5.2.2

A practical workflow includes:

  • Define a cost matrix covering true negatives, false negatives, false positives, and true positives. section 5.2.2
  • Use explicit costs when misclassification consequences can be quantified; otherwise, weight each class contribution to produce a class-balanced loss. section 5.2.2
  • Compare imbalance strategies with precision-recall area under the curve rather than relying only on class counts. section 5.2.2
Table 5.1 Cost matrix for cost-sensitive learning. Subscripts read (predicted, actual)
Predicted ↓ / Actual →
Actual Negative
Actual Positive
Predicted Negative
C00 (TN)
C01 (FN)
Predicted Positive
C10 (FP)
C11 (TP)

Inspect the cost matrix that organizes error penalties by predicted and actual class. section 5.2.2

How Build AI Drug Discovery Pipelines covers it

How deep it goes
Explains cost matrices and class-balanced loss, but stops short of specifying a complete domain-specific cost matrix.
Examples
Uses virtual-screening inhibitor errors, a cost-matrix table, class-balanced formulas, and scikit-learn strategy comparisons.
What you can do after
Apply class weighting or explicit error costs and compare imbalance strategies with precision-recall area under the curve.
How it connects
Connects class imbalance with data augmentation, downsampling, upsampling, class weights, loss functions, and precision-recall evaluation.

Also explained in

Compare how 2 books explain cost-sensitive learning →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Build AI Drug Discovery Pipelines. The section links point to the parts of the book it draws on.