1-Wasserstein distances between districting plans
Project description
wasserplan is a library for computing 1-Wasserstein distances between GerryChain partitions.
Dependencies
wasserplan depends on GerryChain and CVXPY. We recommend installing these dependencies with Anaconda (see the official GerryChain installation instructions).
Using
We principally use this library to compute pairwise transport distances which we (approximately) project into 2D Euclidean space. A simple demonstration of this use case using Virginia congressional districts is available as a notebook (open in Colab).
Performance
By default, wasserplan uses the open-source, lightweight ECOS solver, which is included with CVXPY. However, this solver may exhibit performance issues for large graphs (thousands of nodes). Performance can be improved by using a commercial solver such as MOSEK.
License
This library is available under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file wasserplan-0.1.3.tar.gz
.
File metadata
- Download URL: wasserplan-0.1.3.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.3.0.post20200513 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d4e88ddc9f3a17e93988a7eb905c91e02aa649319e96e672045b65e8a28764ac |
|
MD5 | 0449f46dda7a9d1d9acbbef26bfc6ea9 |
|
BLAKE2b-256 | d7de7ee348e72d3fcf82a328d7d24e523426dac437c31672fdaf296e10bda480 |