Implement layer assignment

for GraphLayout project