liveBook · Manning

Multilabel classification

As explained in Build AI Drug Discovery Pipelines

Multilabel classification is a supervised learning task in which each instance can be assigned multiple class labels simultaneously.

Multilabel classification assigns a set of labels to each instance when several classes may apply simultaneously. In cytochrome P450 inhibition, the question is which of five CYP enzymes a molecule inhibits, including the possibility of none. section 5.4.2

Distinguish multilabel classification from related prediction settings:

  • Multiclass classification chooses exactly one class, whereas multilabel classification predicts several labels for the same instance. section 5.4.2
  • Multioutput classification predicts multiple output variables and can encompass multiclass and multilabel tasks. section 5.4.2
  • Use an independent logistic function for each label rather than softmax, which assumes one correct answer. section 5.4.2
  • Use Random Forests directly for multilabel problems, or train independent label models with MultiOutputClassifier when label correlation is not expected. section 5.4.2

Predicting CYP inhibition

Represent each molecule with five binary labels: CYP2C19, CYP2D6, CYP3A4, CYP1A2, and CYP2C9. A prediction can therefore identify any combination of inhibited enzymes instead of forcing the molecule into one class. section 5.4.2

Because labels may be correlated, one model predicting all labels can consolidate shared patterns. Evaluate ranking quality with coverage error and ranking loss, and aggregate per-label F1 with micro- or macro-averaging. section 5.4.2 section 5.5

How Build AI Drug Discovery Pipelines covers it

How deep it goes
Explains label structure, logistic outputs, model choices, dataset merging, and ranking metrics without deriving algorithms internally.
Examples
Uses five CYP inhibitor labels, merged molecular datasets, RDKit InChI records, and precision-recall performance plots.
What you can do after
Apply it via scikit-learn models to predict multiple CYP inhibition labels and evaluate their ranking quality.
How it connects
Connects multilabel classification with multiclass classification, multioutput classification, logistic regression, Random Forests, and ranking metrics.

Also explained in

Compare how 4 books explain multilabel classification →

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.