Added k-fold partitioning to gencases.py