How to do stratified splitting of Multi-class Multi-labeled image classification data

Complete with code and unit tests.

Stratified sampling is imporant when you have extremely unbalanced machine learning datasets to ensure that each class is evenly distributed across your train/test/validation splits. While there are several solutions for multi-class data, there are few for multi-classs and multi-label datasets. So, I’m sharing my solution below. [Read More]
Tags: code