Skip to content

Commit

Permalink
Merge pull request #54 from thatch/release-gil
Browse files Browse the repository at this point in the history
Mark Construct nogil so it can operate in parallel
  • Loading branch information
fabanc authored Jan 1, 2025
2 parents 46bcd9c + 45c9078 commit fb697ee
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pyvoronoi/pyvoronoi.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ cdef extern from "voronoi.hpp":
VoronoiDiagram()
void AddPoint(Point p)
void AddSegment(Segment s)
void Construct()
void Construct() nogil
vector[Point] GetPoints()
vector[Segment] GetSegments()

Expand Down Expand Up @@ -265,8 +265,8 @@ cdef class Pyvoronoi:
raise VoronoiException('Construct() has already been called')

self.constructed = 1

self.thisptr.Construct()
with nogil:
self.thisptr.Construct()

self.thisptr.MapVertexIndexes()
self.thisptr.MapEdgeIndexes()
Expand Down

0 comments on commit fb697ee

Please sign in to comment.