precincts?

14 views
Skip to first unread message

Dan Ancona

unread,
Oct 29, 2010, 1:32:56 AM10/29/10
to Google Elections Center API Users
I'm starting to play around with this and it's basically just
incredible - I'm working on integrating it into DemDash (demdash.us)
and it's really a game-changer for that project. But I'm having a
bit
of a hard time getting usable precinct codes out reliably. DemDash
is
nonpartisan (although heavily progressive so far) so I doubt it'd
qualify for the DNC's service, plus having the google address
parsing
is a gigantic win.

I'm going by county, and the test links and what I'm seeing get
returned are below. I know someone was talking about exposing some
of
the precincts that are in there - maybe that's what I'm asking for,
although it seems odd that it works for some counties but not for
others. But at any rate I would much rather do this over the API
then
mess with static files. And it'd be great to get it running for the
last four days.

Thanks!

Dan

Alameda
http://pollinglocation.googleapis.com/?q=670%20Grizzly%20Peak%20Blvd%20Berkeley%20CA
for the 'id' field I'm getting "ca:1-200100", that looks like
state:countyfips-precinct" - looks perfect, easy to parse.

San Francsico
http://pollinglocation.googleapis.com/?q=3830%2019th%20st%20sf
returns "ca:75-3832" - also great (and correct)

These aren't:

San Diego:
http://pollinglocation.googleapis.com/?q=18111%20Bandy%20Canyon%20Rd%20Escondido%20CA
returned: 714:13000000739960
expected: something with 100100 in it

Los Angeles:

http://pollinglocation.googleapis.com/?q=3267%20Veteran%20Ave%20Los%20Angeles%20CA
returned: 706:130000004262314
excpected: something with 9000002 in it

Daniel Berlin

unread,
Oct 29, 2010, 9:18:38 AM10/29/10
to election-cen...@googlegroups.com

It's not actually, it's a unique id concatenated with the state.
The unique ids actually have no meaning.
They used to be a unique id from one of the data providers, but they
are normalized/etc, so they do not match anything in the wild right
now.
I wouldn't try to use them.

The unique ids will also be different between each provider.
The main purpose of them existing right now is to enable *us* to
easily be able to identify which polling location/contest is which in
case they need to be blacklisted/changed on a more emergent basis.

*After* this election, we are going to look into what we want to do
around unique ID's.

>
> San Francsico
> http://pollinglocation.googleapis.com/?q=3830%2019th%20st%20sf
> returns "ca:75-3832" - also great (and correct)
>
> These aren't:
>
> San Diego:
> http://pollinglocation.googleapis.com/?q=18111%20Bandy%20Canyon%20Rd%20Escondido%20CA
> returned: 714:13000000739960
> expected: something with 100100 in it
>
> Los Angeles:
>
> http://pollinglocation.googleapis.com/?q=3267%20Veteran%20Ave%20Los%20Angeles%20CA
> returned: 706:130000004262314
> excpected: something with 9000002 in it
>

These don't come from the same datasource, and thus, do not share the
same unique id structure.

Just so you know they are dataset id:unique id.

The unique id is usually just that.
An integer that happens to be unique to the dataset it came from.

The dataset ids we generate.

So basically, hold on a bit, and we'll figure out what we want to do here.

Nathan Woodhull

unread,
Oct 29, 2010, 9:58:37 AM10/29/10
to election-cen...@googlegroups.com
We don't restrict access to our polling place API by partisanship. You
just need to agree to the ToS.

That said, I expect it will be most useful to folks who need to use
VAN precinct IDs, or for whatever reason prefer to use our data set
instead of NOI/Google's. Candidates/State Parties for instance can use
our existing data flows to update and correct incorrect information.

If I was building something completely non-partisan, I would probably
use the Google data.

Nathan

On Fri, Oct 29, 2010 at 1:32 AM, Dan Ancona <afighti...@gmail.com> wrote:

Dan Ancona

unread,
Oct 29, 2010, 12:03:37 PM10/29/10
to election-cen...@googlegroups.com
Daniel thanks for getting back to me - I found the docs after I sent
that and saw that those were unstable IDs, so yah, I won't use them.
But does hold on "a bit" mean more like "after the election" or
"sometime today-ish"? DemDash can translate precinct IDs on the fly,
so leading or trailing zeros or any of the other crazy stuff that you
get in some counties is probably OK. As long as it's in the ballpark
we can do the translations if necessary.

Incidentally the reason we want to key off precincts (and not just
display polling places) is because DemDash has a fairly complete
precinct-detail file for the entire state that includes 5000+ local
districts. So once we get someone's precinct, we're building out a
pretty detailed front-end for their entire dogcatcher-to-whitehouse
government stack, including maps and reps or candidates where we have
them. If you make an account on DemDash and go to Civic Profile you
can see the beginning of this. I wrote a janky street address to
precinct web service (based off the CA voter file), but I guessed/
hoped someone would come along and do this right, exactly like you are.

And Nathan, I assume you're syncing from the CA VoteBuilder, not
pepvan (the VoterConnect VAN) - what are the CA polling places in
there like? I know we have some corrections and consolidations for at
least a couple counties that weren't in the first VIP batch. We don't
have a ton of counties (8 maybe?) but I'd be happy to share an export
or VAN's welcome to wire us into the API-level updating if that's
helpful.

Reply all
Reply to author
Forward
0 new messages