I'm trying to split my data in a stratified way. I think `train_test_split`from `sklearn` doesn't work the expected way on imbalanced datasets.

Here is an example:

```py
from sklearn.model_selection import train_test_split
from collections import Counter

y = [7]*2 + [1]*100 + [2]*3 + [3]*3 + [4]*6 + [5]*100 + [6]*2 + [8]*2
xtrain, xtest = train_test_split(
        y, stratify=y, test_size=0.2, 
        shuffle=True, random_state=42
    )

print(Counter(xtrain))
#Counter({1: 80, 5: 80, 2: 2, 4: 5, 8: 2, 3: 2, 7: 2, 6: 1})

print(Counter(xtest))
#Counter({5: 20, 1: 20, 6: 1, 2: 1, 3: 1, 4: 1})

```

Classes 1 and 5 are distributed the expected way. However, classes that are underrepresented are not well distributed. Classes 6,2,3,4 are well distributed but not 8 and 7. Am I missing something to do this split correctly ?