Friday, April 3, 2009

Sahana Project Proposal

1. Personal Details


Name: Sanjiv Singh


EMail: singhsanjivk@gmail.com


IRC: sanjiv


Education and Experience:


I am doing my Masters in Information Technology from Punjab Technical University, India. I already have a masters in Geophysics and I have been involved with programming for the last 6 years. I have programmed in projects of varying sizes using languages such as C, C++, Java, PHP, Perl and Python. I fell in love with python in 2006 when I started using it for writing sys admin scripts. I started using TurboGears web framework when I was looking for a framework for developing a web application in python. I have also had a look at web2py which is a project requirement for this project and I found it very similar to TurboGears. So I am confident that I will become productive on web2py within a few hours.
I am specially interested in open source development. Google Summer of Code 2008 gave me a chance to get associated with open source developers. I successfully completed the SoC project "Toscawidget Library Using jQuery and OpenLayers"[1] with the TurboGears team under the mentorship of Christopher Perkins. In addition to the proposed GSoC project I also developed a TurboGears Extension tgext.geo[2] that adds geographic capabilities to the TurboGears Web Framework. Since then I have been involved with the TurboGears community and have been contributing in several ways, e.g. contributing to TG subprojects (e.g. ToscaWidgets, tgtools, etc.), documentation, participating in sprints, etc. My Open Source development profile can be seen here . I have also had the opportunity to work for a midium sized Turbogears based ajaxified financial application which is already in production use. The front end for the app was developed using the ExtJS Javascript library which has given me a reasonable level of expertise in Javascript and the ExtJS framework too.


Why am I Suitable for the Project:


I have a reasonable level of expertise with most of skill requirements for the project, i.e. Python, Javascript, Geospatial technologies, OpenLayers and ExtJS as has been brought out above. So I will be ready to get started very quickly with a focus on deliverables rather than trying to learn about the technologies involved.I have a passion for Open Source development and could become a long term contributor to Sahana project.


What do I gain from the Project:


I feel the best way to spend the summer as a student is to participate in the summer of code program. Also an opportunity to work with the Sahana team would get me involved intimately with the project. As Sahana supports a humanitarian cause, this long term association would give me immense self satisfaction.



2. Personal Availability



  • I have reviewed the Important Dates and Times (http://code.google.com/opensource/gsoc/2009/faqs.html#0_1_timeline_5354032302481437_) for GSOC2009

  • I will have exams from May 18 to May 30. This means I will not be actively involved during the last week of community bonding period and the first week of coding period.



3. Project Abstract


The Geospatial Framework for Sahana would provide GIS capability to the Sahana project. The Sahana GIS project page lists several GIS applications that are planned for Sahana the most important one being victim tracing and tracking. The Geospatial Framework would provide a backend and frontend solution for storing, retrieving, handling and processing geospatial data in Sahana. The backend component will be closely integrated with web2py with an option for using GeoServer / FeatureServer / MapServer as decided by the Sahana core team. The frontend will be developed using OpenLayers or a combination of OpenLayers and ExtJS.


An appiclation like tracking and tracing would be best utilized using gps enabled phones / devices. So a facility to upload GPS tracks / positions will also be provided. Eventually it should develop into a phone / handheld based application wherein the location is updated directly from the phone handset.


4. Project Plan


Location awreness is an extremely important aspect of disaster management. Where are the victims and where are my resources? Answeres to these two questions will ensure effective and most optimal utilisation of limited resources towards disaster management. The Geospatial Framework for Sahana will address this problem and facilitate storage, processing, retreival and visualization of spatial (location) data in Sahana Disaster management System.


The technologies to be used for backend and frontend in the framework is not yet finalized. It is expected that these would be discussed on ML and finalized before the coding period begins. In case the backend is implemented in FeatureServer[3], which is python gis server, web2py controller will be able to create FeatureServer objects and save them to Feature Datasore, like shapefile (using OGR) or PostGIS, or SQlite. PostGIS supports advanced spatial capabilities. So switch from current mysql to postgresql needs to be discussed on ML. This would involve sahana modules for handling gis data. The modules will be called in the controller. In case the backend is implemented using GeoServer, features could be stored and accessed directly from client (openlayers) using WFS / WMS or through web2py using the python OWSLib[4] which implemnts OGC services (WFS, WMS) and could server-chain to GeoServer. In this case the sahana gis module will call the owslib services from the OWSLib package and read / write data from / to GeoServer using WFS / WMS (GetFeatureInfo).


The frontend will be implemented using the OpenLayers Javascript Mapping Toolkit.It would be interesting to use OpenLayers along with ExtJS framework which provides sophisticated widgets. The ExtJS layout container widgets could be used to hold the maps and tree widget to create the layer selection tree. Such toolkits are already being used in MapFish. There is a separate project launched under OSGeo recently called GeoExt. It uses OpenLayers and ExtJS. GeoExt could be evaluated and used if found suitable. The deliverables for the frontend would include a set of openlayers / extjs widgets for displaying the Map, controls for zooming and panning, controls for layer switching / layer tree and control for editing.


A facility for uploading GPS tracks / positions will also be delivered. As of now it will be a simple file upload widget at the front end and a gps data processing module at the backend.


5. Project Goals and Timeline


Project Goals:



  • To provide a python web2py backend module for management of geospatial data. Several python gis libraries will be used to achieve this.

  • To provide a standardized GIS frontend capable of displaying maps and other geospatial data (tracks, locations, affected areas, etc.)

  • Advanced widgets for a rich Web2.0 user interface

  • Facility to upload and process gps data


Timeline:



  1. Work already undertaken - Nil so far, as I decided to apply quite late. But as I am very familiar with the technologies involved I can get productive immediately after discussing the technology to be used with my mentor / dev team.

  2. First trimester (20 April - 22 May) - This period will be used mostly for evaluating and arriving at the technologies most suitable for the project. Evaluate backend gis tools, discuss, preferably write experimental code and arrive at a decision. Similar exercise will be carried out for the frontend where required. Python modules for gps processing will be explored. Evaluate OpenGTS and bring out issues of integrating it.

  3. Second trimester (23 May - 6 July)

    • Implement experimental gis backend by Jun 8

    • Code review, fixes and unittests by Jun 21

    • GIS database integration (PostGIS, MysqlSpatial, SpatialLite) by Jul 5



  4. Third trimester (7 July - 10 August)


    • Unittests and Integration tests for database backend and backend documentation by Jul 12

    • Mockups for frontend map, controls and style up for review by Jul 19

    • Basic map with layer switcher, pan and zoom control by Jul 26

    • GPS data upload facility by Aug 2

    • Frontend Extjs widgets, cleanup, finalization and documentation by Aug 10

    • YUI Tests / Test Another Way based JS Tests by Aug 16




[1] http://code.google.com/soc/2008/turbogears/appinfo.html?csaid=E94B59193DB4A185


[2] http://www.turbogears.com/2.0/docs/main/Extensions/index.html#geo


[3] http://featureserver.org/


[4] http://pypi.python.org/pypi/OWSLib/0.3


No comments: