The second evaluation of Google Summer of Code is complete and the results came out a week back and I cleared it. This article explains what I did during the second phase of GSoC building AutoBound.
The main two main tasks I focused on during the second phase of GSoC were:
1. Data Collection
2. The plugin-server pipeline
BBloggsbott's Diary
Recent diary entries
It has been almost one week since coding officially started with Google Summer of Code. As mentioned in my previous post, I have been selected to work as a Student Developer for OpenStreetMap through Google Summer of Code.
I have been working on my project and the experience so far has been great. In this post, I’ll be explaining what I’ve done and you can find the code in the development branch of this repo.
The Action Class
First, I had to create an Action class. The methods of this class will be called when an action occurs. For my plugin, I wanted the user to be able to select an area in the MapView and this area had to be processed. For this functionality, I had to extend the MapMode class (Makes the Action a MapMode and implement the SelectionEnded Interface (this provides the area selection functionality) and override the necessary functions.
Once this was done, I had to add the action class to the MapMode menus in JOSM. I did this by overriding the mapFrameInitialized method of the Plugin class.
Utilities
Next, I created classes that can provide utilities for the working of the plugin. The following classes were created: * DataUtils * NetworkUtils * MapUtils These classes provide functions that can prepare data to send to the server, communicate with the server, add points from the DataSet on the MapView.
Tests
Once all this was done, I started writing unit tests to make sure that the classes are doing what I expect them to do. For this, I used Junit and JOSM’s test utilities. For some tests that involved the methods that communicate with the server, I created a new endpoint in the server for the tests to communicate with. Right now, all the tests are passing.
What I’ve learned
Coding for Google Summer of Code officially started yesterday. I’ve started working on it and so far, things are going good. In this entry, I’ll briefly describe what my project is and does.
The Project - AutoBound
I will be working on building a plugin for JOSM that can automatically identify the rooftops of buildings in a given map area. This will make it easier for contributors of OSM to easily mark buildings and add data.
The tool will have two parts: 1. The Front End — This will be written in Java and will act as an interface between the user and JOSM. The plugin will allow users to select an area on the map. The satellite image of this area will be Base64 encoded and sent to the Back End. 2. The Back End — This part will be written in Python. The Back End will have endpoints listening on a port (default: 5000). When it receives data from the Front End, it is decoded and processed. Image Segmentation is done by a Deep Learning model that has been trained to segment rooftops in an image. Then the position of the nodes that can create a boundary for that rooftop is calculated and is returned to the Front End, where it is displayed on the Map View to the user.
The Back End will also be made available as a Docker image to make it easier to use.
The Timeline
GSoC gives students three months to complete their project. For the first month, I will be working on the Front End of the Plugin. I will be pushing all my code to the GitHub repo every day. For the following two months, I will be collecting and preparing data to train the Deep Learning model, training the deep learning model, integrating it with the endpoints, testing the working of the entire stack and adding documentation. The code for the server will be pushed to this GitHub repo. I will also be posting updates on my work every week on Medium and here.