Hello
This problem about combine sets or tree branches which have similar numbers, @DavidRutten Already solved it years ago with c#
And i think loop can do the same thing as the script but is there a method to do that with components or Python
In this specific case, @Jakinta, you have final set restults that doesn’t overlap.
Region union is not good in this matter.
Replace 11 with 3 and 3 with 11 on first panels and you’ll understand.
it’s a step for the right solution but as @maje90 said , the solution don’t work where branches have a single item, maybe will work by using set difference between the original tree and the result