Remove duplicate points bug

I was using the RemoveDuplicatePts from kangaroo 2 and it gave me a very strange and unexpected result. After feeding in a collection of points, the component was outputting a point that wasn’t even in the input.

I checked the same using Cull Duplicates and it seemed to work fine.

Hopefully it’s an oversight on my part and not a bug.

remove duplicates bug.gh (81.1 KB)

Ah, it looks like for inputs like you have here that are a mix of nulls and valid points, the nulls are getting converted to points at the origin.
If you use Clean Tree on your input this won’t happen.
I’ll also fix it in the component to avoid this issue in future. Thanks for pointing it out.

The same thing happens with a script component if you set the input data type to point and pass it a null.

2 Likes

No problem. Thanks for your clarification and quick reply!