Tuesday, November 15, 2011

Hectic Times


I've been unable to update this blog regularly because, as you can see by my title, I've been going through hectic times.
Firstly, i'm still very much involved in AMPATH work - so much so that I've been unable to spend any time with my beloved OpenMRS core over the past month or so.
However, We've definitely making progress. Ada is even getting me an AMPATH tee shirt (So that I can say 'I've been there, and done that'. ) Poor Ben (our Director) has been asked to do the purchasing (since he's frequently flying to and fro between Eldoret and Indy).

I'm also getting an Muzungu tee shirt. Muzungu is basically African for 'the white people' (in Swahili is means 'confused person wondering about' :-D ).

 I guess Muzungu Tee shirts are somewhat of a fad of Regenstrief and PIH employees. I think its also very popular among westerners working in Africa. But anyway, I'm really looking forward to the tee shirts, and hoping that Ben wont get them in the lemon green and pink colours that he suggested :-)

Other than this, I'm also working on two other OpenMRS related projects, as part of something that Professor Solovitz of MIT suggested. Dr. Mamlin is helping me with one of these, while my favorite lecturer from IIT is helping with the other. (well, formerly IIT, and now with the Swinburne University, AUS).

Hopefully, we'll know the outcome of these efforts by Dec - Jan. But until that, its all confidential.

I'm also trying to continue with Dr. Shauns' Patient matching improvements, but its been really hard to find the free time.
And plus, my university does not understand that I'm really busy, and keeps assigning Course works.

Oh well.......




Friday, November 11, 2011

My work with AMPATH - Part two

                     
It's been some time since I published part 1 of my AMPATH story. I couldn't follow up with part two because the project is still very much ongoing, and I've only just committed the latest changes....


But let me try to pick up this story where I left off, and write at least a chapter or so on our progress.


Well, (resuming our narrative...) Ada tried out my new omod on an openmrs server, and sure enough it worked.
So she went ahead and uploaded the new module to the AMPATH research server, and suddenly it did not work.


The error was as follows,




Error Starting Module – Patient Matching
Error while trying to start module
Error while running sql: DROP TABLE IF EXISTS `openmrs`.`persistreportdata` . Message: DROP command denied to user 'amrs_user'@'localhost' for table 'persistreportdata'

I has just started digging into this problem when I got a mail from Win (Nyoman Ribeka) a Regenstrief developer and one of the fist contributors (well, actually THE first contributor) to the patientmatching module.

Apparently Ada had forwarded him the stack trace, and it had taken Win all of five minutes to come up with the solution.

The problem was that we had tested out the fixes using an 'openmrs' database, while the  AMPATH database was named 'amrs' ! . The issue was being caused by a database dependent code snippet that had somehow by-passed our vigorous code review process.

So naturally our fixes worked on the openmrs test environment, and crashed on the AMPATH environment.

But anyway, it was quite easy to fix once we understood the cause. we traced the faulty code to the sqldiff file ( an SQL inset into statement had the database name 'openmrs' prepended to the end. This was unnecessary, and was causing our problems. )

So I fixed it, tested it out and sent Ada the latest omod...

And was that the end of our problems ? not quite, 

But that is for later. Do stay tuned for part -3 !

Thursday, November 3, 2011

My work with AMPATH - Part one


I've been busy working with AMPATH engineers over the past week. We did a lot of important work to help AMPATH switch to the latest patient Matching module, and I'm happy to have played a role in getting this up and running.

For all of you who don't know what AMPATH is, its practically one of OpenMRS's birthplaces. For more details, please visit here.

It all started off after I got a mail from Dr. Shaun (THE Dr. Shaun from Regenstrief) asking if I could help the AMPATH people upgrade their system to the latest patient matching release. basically, AMPATH was using OpenMRS 1.8.2, and wanted to move on to the latest version of our module (which was supposed to be 1.2.2, but ultimately turned out to be 1.2.4 due to all the changes that we made)

Naturally, I was pleased to jump in and help out (who wouldn't ?)

So I contacted Ada (Ada Yeung, who works with AMPATH)  got access to AMPATH test server, and started checking out the system. Unfortunately, the test server was somewhat muddled up, mainly due to the large number of tomcat and OpenMRS modules installed everywhere.

So I contacted James (James Egg from Regenstrief) sorted everything out, upgraded the test server and got the latest running. The Upgrading process went pretty smoothly ( You will really admire the OpenMRS design once you see how easy it is to switch to - fro and upgrade with a live DB) and I didnt have any data problems at all.

So I went ahead and fixed a number of major showstoppers.

Dr. Shaun and Ada were very happy with my work, especially with the bug fixes.

So I committed the new changes, and stood down for the testing to begin.

And so was that the end of the story ? oh no, this was just the beginning. It all got pretty complicated after that...

Expect the full details in the next blog post !!!!


Thursday, October 27, 2011

I've just been published by Google

A quick post to say that I've been published on the Google blog.

More specifically, an article I wrote on my experience at the OpenMRS implementer conference was published on the Google opensource blog.

This is a really big deal to me, since its the first time I have been singly picked out by Google. However a lot of the credit should go to my good friend Michael Downey, who actually spearhearded the entire effort. If it wasn't for him, I'd be just another boring old student.

The article appears here (http://google-opensource.blogspot.com/2011/10/openmrs-welcomes-with-open-arms.html)

Its been modified slightly so that none technical people can understand it better, but otherwise its pretty much the same.

PS: I can honestly say that this is the "one small step for me, one huge step for my future" moment of my career.

Thank you Michael !!!!!

Thursday, October 20, 2011

OpenMRS patient Matching module

I've recently started work on the OpenMRS patient Matching module. Its a complex and intriguing piece of software planned by Dr. Shaun Grannis of the Regenstrief institute.

Dr. Shaun is qualified in both engineering as well as medicine (he's an MIT graduate)  and his mathematical training came really helpful in my efforts. I'm also being helped by James Egg, also of the Regenstrief institute. He has been a great help with design planning and domain expertise.

I also found out that Win (Nyoman Ribeka) of OpenMRS had initially got involved in OpenMRS working on the PatientMatching module as a gsoc student ! (this was in 2008)

My work on the module is aimed at calculating mutual information scores for pairwise combinations of columns. This will ultimately make the matching algorithm more efficient.

The work is quite challenging, but intriguing and interesting. I have already made much progress in my work.

for further reference, documentation on the module is available on the wiki here

Credit must also go to Gautami, a fellow Gsoc student who worked on this module during Gsoc 2011.


Meeting the OpenMRS community at Kigali, Rwanda

I've been unable to post much on my blog recently. The reason for this was that I was away at Kigali, Rwanda, attending the annual OpenMRS implementer conference.
So much things happened there that I've been tied up with a lot of important //TO DOs that kept me busy for a while.

but first and foremost, I'd like to share an article I wrote on the event. This was posted on the OpenMRS blog here.

However i'm re posting it here because I really like it. Enjoy !



Google Summer of Code Student Meets the OpenMRS Community

Recently, I had the rare privilege of attending the annual implementers conference of OpenMRS, my Google Summer of Code (GSoC) mentoring organization.
Thanks largely to the conference sponsorship by Google, OpenMRS was able to fund my week-long visit to Kigali, Rwanda. I travelled over 4,500 miles to Rwanda, and spent a week meeting with core OpenMRS developers, other volunteers, implementers, service providers and researchers who had gathered there for the conference.
OpenMRS Implementers Meeting 2011
OpenMRS Implementers Meeting 2011
Arriving at Kigali, I was amazed at the diversity and fellowship amongst the community, and of how happy they were to accept me as their own.
I took part in a pre-conference hackathon, and visited the OpenMRS implementation at Rwanda’s TRAC Plus health clinic. I listened to why implementers from Village Health Works used an Access database for their Burundi clinic, and to Dr. Joaquin Blaya’s work with Interactive Voice Response. Eduardo Jezierski, the CTO of InSTEDD, talked to me about their work in Haiti, while Christopher Bailey of the World Health Organization spoke of his experience working with developing countries.
I also enjoyed a Chinese meal with a group of US-based developers for the AMPATH program in Western Kenya. (Ben Wolfe, director of OpenMRS API Development taught me how to use chopsticks). I visited the Kigali Genocide museum, played cards with a group of research scientists, academics and other developers and spilled my drink all over a director’s laptop. I had dinner with OpenMRS co-founder Dr. Burke Mamlin, brought a drink for co-founder Dr. Paul Biondrich and had breakfast with an MIT graduate who explained why he quit building space satellites and an engineering career to enroll in medical school.
My participation at the conference was an eye opener for several reasons. Firstly, it helped me make the change from “GSOC student” to fully fledged community member. I stopped being just an offshore volunteer, and understood my organization for what it really was.
I saw my project as a community, a group of vibrant, talented and extremely capable people with a wide range of interest in software development, research, medicine, health informatics and public health. I understood that OpenMRS is not “just” OpenMRS, but a massive network of implementers, developers, healthcare workers and other organizations.
I saw the dedication and professionalism of community members, and their sincere concern to help make the world a better place. I also realized how community members were supporting themselves while enjoying what they do by serving as consultants, developers and service providers.
However, I believe that my experience at the conference highlights something that Google should definitely look into – the inability to ensure that GSoC students continue being a part of the open source community once deadlines are over. As Google clearly states on their website, GSoC is organized with the aim of encouraging students to contribute to open source projects. However it’s undeniable that many students consider GSoC as a get rich scheme for their internship year.
I feel that this is mainly due to four reasons – firstly because many GSoC students are offshore based, and see their project as yet another software, secondly because many of them consider it as a internship with strict deadlines, thirdly because they are unable to make the transition from volunteer to community member and finally because they fail to understand that open source developers have ways of making money while doing what they enjoy.
As I see, the best way that Google can avoid this is by tearing down the wall between student and community member.
Google can do this by introducing more flexible methods of student evaluation, by giving more weight to community participation in their evaluation criteria and possibly by moving up student application dates so that students can apply several months in advance, allowing the community to assess how they get up to speed on domain knowledge and technology stacks. This way, students will be familiar with their projects, the community will be aware of their capabilities and stronger ties would link the student with his organization.
Ideally, all this would happen before the student is even selected for GSoC.
Ultimately, I believe that both Google and mentoring organizations should consider methods to ensure that GSoC does not end with “successful project completion”. Also consider – why do we even get a certificate saying that we “are recognized for participating in GSoC”? It should say that we are “recognized as a successful community member” of our respective mentoring organizations.

Saturday, October 1, 2011

OpenMRS Sync module


I've been involved in the OpenMRS sync module.
We had a sprint for this a few weeks back. Basically, we were aiming to prepare it for a 1.0 release.

The sync module is  great concept. You can check it out here.

Its purpose is to let users who have multiple sites with separate databases to copy data from each other. Databases are defined as parent or child databases.
The Parent is always the computer or site that is most central. Multiple child sites send their data up to the parent site for dissemination. Children/parent sites can be set up in a multi hierarchy way.

Apparently work on the Sync module was started as far back as 2007 by Christian Allen of PIH.

Its also noteworthy that the Sync module is the first ever OpenMRS module that i'd been involved in - all my prior work was on the trunk.

Even more noteworthy, not a single one of my commits (thankfully) broke the build during the sprint .....