~shree
20Apr/149

Polling Day Voter List Search Service!

The whole of Karnataka (actually a little more than half) voted on the 17th. So did I.

Chetana (my wife) and me have always voted in different polling booths. This time, these were in different schools. The voter turn-out was expected to be higher this time. So we were keen to cast our votes as early as possible.

I dropped off Chetana at her assigned polling booth. Looked like a lot of people waiting there. So I immediately rushed to the school where I was supposed to vote. There were a lot of people 100 meters away from the polling booth. Surprise -- very few queued up outside the polling booth itself ! A middle aged lady & her daughter were struggling to figure out where they were supposed to vote. With my mobile, and their voter ids, I quickly figured out that they were supposed to vote in the next polling booth.

Walking back to my car, I noticed that the number of people waiting to lookup their names in the voters list had increased. Political parties typically put up benches 100 meters away from polling booth. Party workers are stationed here with voter lists. By searching the voter lists, volunteers figure out which booth they need to go to vote. These serve as a last ditch campaign effort, in the name of service. Apparently, this service is also used to track who voted in a lot of areas, many a time resulting in bogus voting.

Searching the list is a cumbersome manual process. One improvement this time was the presence of laptop toting folks with an internet connection. These guys would use the election commission's website to search for the details. The website provided search option with an "EPIC number", as well as by name. The EPIC number is printed on the voter id card. Searching by name sucks; I haven't seen it yield any result till now. If one were lucky, the search would finish in a few seconds. More often than not, the website just wouldn't work ! The website must have been overloaded. The bottlenecks for the search turned out to be the internet connection, as well as the election comission's website. The number of people waiting to search the list kept growing. Chetana and me helped a few people with our mobiles. But this was clearly not enough.

There were at-least 30 people on the desks, searching through the voter lists. This seemed ridiculous to me, as well as a massive waste of manpower. If search were a snap, they could go home - and do something else more useful.

I knew that the voter lists are available online, and can be downloaded freely. The online versions have details of voters sans their photographs. If this were downloaded and searched, then we could directly search in them - fast and accurate, without the vagaries of the internet connection and the website status. Something that should ease voting. I came back home and quickly got down to work. I wanted to quickly hack up a working solution.

Finding the voter lists online was easy (e.g. the voter list for our constituency is here). I downloaded one, and ran "strings" on it. Surprise surprise ! No usable names. Googling and looking inside the file gave me the answer - the stuff inside the downloaded PDF files were encoded using a method known as "FlateDecode". Searched some more on how to decode this. Found pdfinflt.ps. With ghostscript, creating a PDF with decoded text is then as simple as :


$ gs -- toolbin/pdfinflt.ps infile outfile

Decoding the text in the PDF file happened in a snap ! I could see my name in the voter list. This was exciting. Next, I had the task of parsing the files and extracting the voter data from it.

In a couple of hours, I implemented this in python (available online at github - feel free to use it). Basically, I created a CSV file with the voter information. Each line had information about the booth, serial number, name and EPIC number. Looking up my neighbours' was the first real test. Many voter lists had a lot of content in kannada, which I was not able to process. But this didn't hurt much, as the EPIC numbers and the rest of the critical information were available.

Satisfied, I got ready to supplement the efforts of the folks near the booth. I posted about this on Facebook, and the response from my friends was encouraging. Praveen Avrur pointed out that the same information could be got by sending an SMS with the content "kaepic" followed by the EPIC number to 9243355223. I was excited - I was about to try out my little program in real time, and solve a real problem. Chetana was supportive, but also a touch worried. She warned me to be careful near the polling booth.

It was noon. New channels were reporting that 30% voting had happened. That's 70% folks that I could potentially help, I told myself. It was not as if I wasn't aware that 100% of the junta doesn't vote. If you're doing something though, you better believe in the exciting outcomes!

Post lunch, I was back near the booth. A sticker on the lid on my laptop had instructions on how to send an SMS to get voter details. In my laptop, I had stored voter lists for my area and a few surrounding areas. I took some time to survey what was happening. The scene was un-inspiring. There were very few voters. 6 benches of party workers on either direction of the school were getting bored to death - almost. A few laptop toting folks were there too. "Net is down", "net is slow"... same problems. Given the low turnout, I was thinking of returning home and resting.

I got chatting with a few youngsters. Mainly because they looked approachable, but also because they had a free chair next to them. Turned out they were students of Global Academy of Technology, a near-by engineering college. They were having a good time. They had one laptop with some internet dongle, and a few printed voter lists. They were also grumbling about the slow network and the unreliable website. I decided to wait and observe what happens.

Soon enough, a voter came along with a card. Net down. A few minutes passed by. No luck. I got my laptop & searched. Success! The students were impressed. And I decided to continue. Soon, more people started arriving. At first, we searched for the voter ID both in my database, and online. This was mostly for verification purposes. I didn't want any bugs in my list to affect voters!

My search was very fast - almost instant. Soon, the students stopped the online search - except for a few cases where voters who were supposed to go elsewhere landed up in the wrong place. This was my real victory. The new workflow was smooth - voters turn up, the students read out the number, I punch it in and give them the results. They then fill fill out a chit with the booth and serial number in the voter list, and off the voter goes. My method had a few advantages even over the election commission's website - searching by name actually worked - and so did fuzzy searches! I was able to help a few folks who turned up even without voter cards. The process was so smooth that folks from the next bench started redirecting folks to our bench.

When I got a break, I tried explaining to the students how my system worked. They were quite impressed that this method gave such nice results. However, I was not convinced that they understood my detailed explanation. I was trying to give some gyaan to them about how engineers should try to solve problems around them. After this effort, they started calling me "uncle" 🙂

The few hours I spent at the bench helping voters search the names were quite an eye-opener for me. Lots of technology exists all around us. And yet, ensuring that it reaches all the way to the place where it matters is not an easy task. I wished I could have replicated my search method on other laptops around me, but there was no time.

Polling closed at 6 PM. Chetana came by around a little earlier to see what was happening. Voting had almost stopped by that time. After a bit of chit-chat, it was time to close the laptop.

I collected some statistics after I reached back home - my searches had helped 74 odd voters. I was able to prove to myself that doing a little bit can make a difference. I went to sleep a happy man.

Comments (9) Trackbacks (0)
  1. Oh wow ! Taking part in the system instead of just complaining ! Way to go Shree!

  2. excellent Shree

  3. good job !!! hope this deed becomes an eye opener in times to come (Y)

  4. Thanks Johnny, Abhikit & Karthik ! A little bit of encouragement goes a long way 🙂

    I’d be even more happy if somebody would take this, and use it somewhere during this election. My code won’t work with indic characters (e.g. kannada in our case); I am working to fix this.

  5. Glad to see your work, Shreekumar. Vivekananda Pani referred to your blog in a mail to me today. I have been working with electoral rolls for the past three years, trying to help the system. You can read about some of my activities in my blog-posts at pgbhat.wordpress.com

    It will be nice to discuss our interests and work.

  6. PG Bhat : Great work from you too! Look forward to interacting more with you.

    Other readers: please lookup http://pgbhat.wordpress.com/ . Mr Bhat has done excellent work!

  7. Great 👍🏼 🙂

  8. Amazing work!! Identifying and solving simple yet real and practical problems like this is the key to improving the quality of life of people! Hope this scales up, and hope that a big community of people is formed who can use simple technologies to solve real problems!

  9. All Indigenous indian that is main internationally and locations. Within our selection region you’ll stumbled upon a large selection of the absolute most spectacular coming megastars nearing satisfy anyone and fashionable Chandigarh Call Girls superstars, mature film celebrities or more!


Leave a comment


No trackbacks yet.