API reference

Region Methods

Model based approaches for aggregating a large set of geographic units (with small footprints) into a smaller number of regions (with large footprints).

region.AZP(gdf, w, attrs_name[, n_clusters, ...])

AZP involves class offering the implementation of the automatic zoning procedure algorithm.

region.MaxPHeuristic(gdf, w, attrs_name, ...)

The max-p-regions involves the aggregation of n areas into an unknown maximum number of homogeneous regions, while ensuring that each region is contiguious and satisfies a minimum threshold value imposed on a predefined spatially extensive attribute.

region.RandomRegion(area_ids[, num_regions, ...])

Randomly combine a given set of areas into two or more regions based on various constraints.

region.RandomRegions(area_ids[, ...])

Generate a list of RandomRegion instances.

region.RegionKMeansHeuristic(data, n_clusters, w)

Solve the region-K-means problem with the constraint that each cluster forms a spatially connected component.

region.Skater(gdf, w, attrs_name[, ...])

Skater is a spatial regionalization algorithm based on spanning tree pruning introduced in [ANCdCF06].

region.Spenc(gdf, w, attrs_name[, ...])

Spatially encouraged spectral clustering found in [Wol18].

region.WardSpatial(gdf, w, attrs_name[, ...])

Agglomerative clustering using Ward linkage with a spatial connectivity constraint.

Locate Methods

Exact solution approaches to facility location modeling problems.

locate.LSCP(name, problem)

Implement the Location Set Covering Problem (LSCP) optimization model and solve it.

locate.LSCPB(name, problem, solver)

Implement the Location Set Covering Problem - Backup (LSCP-B) optimization model and solve it.

locate.MCLP(name, problem)

Implement the Maximal Coverage Location Problem (MCLP) optimization model and solve it.

locate.PMedian(name, problem, aij, weights_sum)

Implement the \(p\)-median optimization model and solve it.

locate.KNearestPMedian(name, ai_sum, ...[, ...])

Implement the P-Median Model with Near-Far Cost Allocation and solve it.

locate.PCenter(name, problem, aij)

Implement the \(p\)-center optimization model and solve it.

locate.PDispersion(name, problem, p_facilities)

Implement the \(p\)-dispersion optimization model and solve it [Kub87].