scikit-learn/scikit-learn — pull request #3128 by nmayorov (2014-05-03 15:30:28+00:00)
Title: FIX: Handling of multilabel targets in cross_val_score

Currently ``StratifiedKFold`` is used as a split strategy in ``cross_val_score``. But it won't work correctly if ``y`` is multilabel, i.e. a label indicator matrix or a sequence of sequences.

I added a couple of lines that check the type of ``y`` and if it's multilabel — simple ``KFold`` strategy is invoked.