Fix last batch partitioning.