Simple client for interacting with PlanScore’s experimental web API.
PlanScore CLI is available from Python’s package index:
pip install PlanScore-CLI
Score a single plan:
planscore-client <API token> <Input GeoJSON> <Output JSON>
See API Sample Request
for details on input GeoJSON formating,
API Sample Response index_url
for details on output JSON content.
Please contact [email protected] to request an API token.
Score many plans in parallel with
GNU Parallel
(documentation).
Example plans in ok-example
have been exported from
Dave’s Redistricting App
samples linked from
Oklahoma Senate Redistricting Page
on April 27, 2021.
parallel planscore-client <API token> '{}' '{//}/score-{/.}.json' \
::: `ls -1 ok-example/*geojson`
The command above will generate ok-example/score-*
files such as
this one. Each score will also
be visible as a public PlanScore result page like the ones below.
- Public map submission 1 → PlanScore result 1
- Public map submission 2 → PlanScore result 2
- Public map submission 3 → PlanScore result 3
- Public map submission 4 → PlanScore result 4
- Public map submission 5 → PlanScore result 5
- Public map submission 6 → PlanScore result 6
- Public map submission 7 → PlanScore result 7
- Public map submission 8 → PlanScore result 8
- Public map submission 9 → PlanScore result 9