added support for more than default group size