changed code to assign partitioned parent