<｜begin▁of▁sentence｜>### Instruction:
Given a set of 2D points, how to calculate the convex hull either returning the indices of the corner points in the input point set or the coordinates of the convex hull's vertices?
### Response:
from scipy.spatial import ConvexHull
import igraph as ig

# Given a set of points
points = [(0, 0), (0, 1), (1, 0), (1, 1), (0.5, 2)]

# Calculate the convex hull
hull = ConvexHull(points)

# If coords is True, return the coordinates of the hull's vertices
if True:
    hull_vertices = points[hull.vertices]
else:
    hull_vertices = hull.vertices

print('Convex hull vertices:')
for vertex in hull_vertices:
    print(vertex)
<|EOT|>
