Skip to content

A web app for the generation and display of heat maps derived from geographic sensor data.

Notifications You must be signed in to change notification settings

karpfen/sensorWebView

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SensorWebView

Description

This web viewer can be used to call a web processing service to generate heat map layers which are derived from sensor data and display them in a web map. The generated maps can be tweaked by the user using the provided user interface for defining kernel density radius, type of sensor and target dates. The screenshot shows the software's user interface along with some sample output.

Screenshot of the web app's user interface

Acknowledgement: The JavaScript libraries and map data used for the user interface are jQuery, OpenLayers 3 and OpenStreetMap.

Installation

This software is designed to be run as a Tomcat webapp. To install, simply clone this repository in the Tomcat webapp directory and restart Tomcat. The application should then be available under localhost/sensorWebApp.

The map overlay is generated by a local GeoServer instance with the WPS (Web Processing Service) extension installed. For further information, see the Tomcat 7, GeoServer and WPS installation guides.

Because of the many available versions of the used software products, not all combinations can be guaranteed to work. Setups in which this software was tested successfully are

  • Tomcat 7 and JRE 1.8.0_91, running on Ubuntu 15.10 with GeoServer 2.8.3
  • Tomcat 8 and JRE 1.8.0_92, running on Windows Server 2012R2 with GeoServer 2.9.0

In all cases the data was stored in a PostgreSQL 9.3 database with a PostGIS 2.1 extension.

Configuration

SensorWebView

The credentials for the database have to be stored in Tomcat's conf/dbConfig.xml in the following form

<?xml version="1.0" encoding="UTF-8"?>
<config>
    <jdbc>
        <driver>org.postgresql.Driver</driver>
        <url>jdbc:postgresql://myHost.com:5432/dbName</url>
        <username>myUsername</username>
        <password>myPassword</password>
    </jdbc>
</config>

GeoServer

To create heat map layers, the database table has to be published on GeoServer first. After that, a style has to be defined in form of an SLD (Style Layer Descriptor) document, which is then applied to the layer. The file ./sampledata/sampleStyle.sld is a template SLD for use in this application. To use it, the element <ogc:Literal>heartrate_int<ogc:Literal> has to be changed to the respective table column name from the data to be represented.

Data Requirements

The data from which the heat maps are derived has to be point data of the PostGIS datatype geometry and feature a timestamp. Also, at least one weighting factor represented by a numeric data type has to be present. In this case, these are sensor data. The file sampledata/sampleDBtable.sql contains the SQL query for creating a minimal example for a table with 100 randomly generated data points that can be used for testing this software.

About

A web app for the generation and display of heat maps derived from geographic sensor data.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published