Our team has just open-sourced the MarineTraffic AIS density maps toolbox, a set of modules that supports processing AIS data while improving its transformation into actionable visualisations (such as density maps). The code is written in Python for simplicity, readability, and overall ease of use.
MarineTraffic and community
From the very beginning, MarineTraffic was built as a community project – the project initially harnessed the willingness of volunteers with an interest in shipping and the sea to host AIS receivers in and near ports and coastal areas (1).
From the Aegean and the eastern Mediterranean, the community has spread across the world – we now have over 5000 active AIS- receiving stations located across more than 180 countries around the world.
Even now, MarineTraffic remains a community project, facilitating the exchange of AIS data, vessel photographs, voyage information, and much more.
In support of the community, MarineTraffic is making publicly available, under a Creative Commons license (CC BY-NC-SA 4.0), a free AIS processing tool.
What is the MarineTraffic AIS density maps toolbox?
Density maps support a bird’s eye view of vessel traffic, by providing an overview of vessel behaviour, either at a regional or global scale in a given timeframe. This is one of the most popular data products offered by MarineTraffic today.
One of the most complex data science tasks is preparing the underlying data for visualisation, as any inaccuracies in the underlying data, due to sensor noise or other factors, evidently lead to erroneous interpretations and misleading visualisations. Sometimes the error is acceptable for a given use case while on other occasions it may lead to erroneous interpretations.
To support and simplify the entire process from AIS data to density maps, we release the MarineTraffic AIS toolbox which includes the modules described below.
AIS Cleaning Module
Trajectories are never perfectly accurate due to sensor noise and other factors. In most situations, it is necessary to apply algorithmic techniques to the data to smooth the noise and potentially decrease the error in the measurements.
This module also includes a number of simple data reduction techniques. The main objective of such trajectory reduction techniques is to reduce the size of the dataset so as to make it operable without compromising too much of its precision. For this reason, several filters are applied including filters to remove empty fields, invalid movement data, and invalid vessel details and to downsample the data according to user-defined parameters.
Density Maps Module
The term “vessel density” has several connotations and thus is used with several meanings in this domain. Therefore, vessel density can refer to
- the average number of vessels detected within a defined geographical area (spatial grid) in a given timeframe;
- the average number of crossings within a defined geographical area (spatial grid) in a given timeframe (often also referred to as “vessel traffic density”);
- the total vessel presence times within a defined geographical area (spatial grid) in a given timeframe;
There is a considerable difference in the methods used for the creation of density maps according to the definition used, including calculations based on the number of vessel positions detected, the number of vessel tracks, their length crossing a given area, and many more variations.
Here we refer to vessel density as total presence time. AIS is the most commonly used dataset for the generation of density maps. This module provides a number of functions for the conversion of AIS data into density maps.
Our team is proud to share the results of its hard work and hopes that the community will not only benefit from it but also further improve it or even contribute to it in ways that we have not even imagined yet. If you are interested in trying out the toolbox, you can find its code and documentation on GitHub. We look forward to seeing what people will do with the MarineTraffic Toolbox and would like to hear your comments.