Skip to content

pybind11 bindings to the graph-cut optimization (GCO) library by Veksler and Delong.

Notifications You must be signed in to change notification settings

agoose77/gco-ext

Repository files navigation

gco

tests-badge pypi-badge

A Python interface to the gco library (modified for repackaging from the original source)

The exposed GCO<XXX>Graph classes are available under the gco root namespace.

See the research homepage for license and usage information.

Neighborhood

Without the ability to easily create C++ arrays-of-arrays in Python, a GCONeighborhood class is exposed which builds pointers into flat arrays:

neighborhood = gco.GCONeighborhood(count, site, cost)

where count[i] is the number of neighbours for site i, site[j] is the site of the jth cumulative neighbour, and cost the corresponding cost for such a neighbour.