Getnumpartitions