compas-dev / compas-dev/compas
unexpected behavior of `compas.geometry.convex_hull`?
- Dominant language
- Python
- Stars
- 386
- Forks
- 122
- Avg merge
- 11d 46m
- Merged PRs (30d)
- 1
Description
Not sure about this one, maybe I'm using it wrong but getting an unexpected result when running `convex_hull` (the pure python one) on a collection of co-planar points.
**To Reproduce**
1. Create planar surface in Rhino with a cutout along one of the edges.
2. Run following GH code:
```python
from compas.geometry import Point, convex_hull
from compas.scene import Scene
vertex_locations = [Point(*vertex.Location) for vertex in brep.Vertices]
hull = convex_hull(vertex_locations)
scene = Scene()
for face in hull:
for v_index in face:
scene.add(vertex_locations[v_index])
a = scene.draw()
```
I'd expect only the points along the convex outline of the surface to return but two internal points are included:

**Desktop (please complete the following information):**
- OS: Windows
- Python version 3.9
Contributor guide
Assessment
This issue has not been assessed yet.