joe-jordan/pyvoro — pull request #3 by christopherpoole (2013-08-19 00:11:04+00:00)
Title: Get correct constructor for numpy arrays

When points are parsed as a numpy array, the vertices returned by `compute_voronoi` are empty.

Specifically, using `obj.__class__` to detect type for numpy arrays will result in the empty arrays as their type `` is not used for initializing them directly. The `get_constructor` function added to `voroplusplus` checks specifically for a numpy array and returns the factory function, otherwise returns `type(obj)`.