Skip to content

About

Open-data pipeline and live map of winter ship traffic in the Gulf of Bothnia: AIS + icebreaker + FMI ice data, DuckDB, clustering of ship behaviour in ice

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

How ice changes ship behaviour in the Gulf of Bothnia

Every winter, ships sailing to northern Finnish and Swedish ports have to cross hundreds of kilometres of sea ice, often behind an icebreaker. This project collects open ship-tracking (AIS), icebreaker and ice-chart data for a full winter. It then measures how ships actually behave in ice: sailing freely, following an icebreaker in a convoy, waiting, or crawling slowly.

Author: Rabiul Islam · MSc Data Analytics, University of Turku

Project website: https://rislam21.github.io/winter-navigation-ice/ · Live map: https://rislam21.github.io/winter-navigation-ice/map.html (ships and icebreakers, updated every 10 minutes)

Every change to the project is recorded in PROJECT_LOG.md.

Results so far (historical analysis, 2006–2026)

Finding: ice doesn't reduce how many ships come to the Gulf of Bothnia. It costs time: longer waits for icebreakers and more hours at sea. This winter's live data is collected to measure exactly that.

How severe each winter was

Ice volume over each winter in the Gulf of Bothnia (FMI ice charts via Copernicus). Harshest: 2010–11, 2009–10, 2023–24, 2012–13. Mildest: 2014–15, 2007–08, 2019–20. There is no steady trend towards milder winters, and harsh winters still come back. 2015–16 is left out because its file in the Copernicus archive is incomplete.

Winter severity vs shipping

  • Left (EMODnet, 7 winters): cargo + tanker vessel-hours in Dec–Apr compared with the summer before. Usually 0.89–0.95, but 1.05 in the harshest winter, 2023–24. EMODnet counts hours at sea, so slower ships and waiting add hours.
  • Middle (Arctia / Fintraffic season reports): average icebreaker waiting time rises with severity: 2.6 h in 2019–20, 4.8 h in 2024–25, 6.4 h in 2023–24.
  • Right (HELCOM, 14 winters): yearly cargo + tanker crossings hardly depend on ice. The ups and downs follow the economy (lowest in 2009, the financial crisis).

Caveats: few winters, and one point (2023–24) drives the left trend, so treat these as hints, not proof. HELCOM 2017–18 are not published and 2021–22 use a different method, so they are excluded. Details: historical/README.md.

Pipeline

flowchart LR
  subgraph S["1. Data sources (free)"]
    A["Digitraffic AIS<br/>ship positions"]
    W["Winter navigation API<br/>icebreakers, dirways"]
    I["FMI ice charts<br/>via Copernicus"]
  end
  T["cron-job.org timer<br/>every 10 min"] --> C["2. Collector<br/>GitHub Actions"]
  A --> C
  W --> C
  C --> P
  C --> L["Live map<br/>GitHub Pages"]
  subgraph ST["3. Storage"]
    P["Parquet files<br/>data branch"] --> SF["Seafile 500 GB<br/>backup"]
    P --> D["DuckDB<br/>SQL over Parquet"]
  end
  I --> D
  H["Historical archives<br/>ice, EMODnet, HELCOM 2006→"] --> AN
  D --> AN["4. Analysis<br/>clustering + prediction"]
  AN --> R["5. Results dashboard<br/>planned"]
Loading

Live map: https://rislam21.github.io/winter-navigation-ice/map.html · Whiteboard version of this diagram: https://claude.ai/artifact/Km7NY1eGybHitQaF32iCzR

Part Tool Runs where
Collect ship positions + icebreaker data src/collect.py GitHub Actions, started every 10 min by cron-job.org, free
Store Parquet files on the data branch, backed up to Seafile GitHub + your laptop
Ice thickness src/get_ice.py (Copernicus Marine) your laptop, once a month
Query + analysis DuckDB, pandas, scikit-learn (src/analyze.py) your laptop

Data layout (on the data branch)

data/ais/date=2026-12-03/101000.parquet        ship positions, one file per run
data/vessels/date=2026-12-03/10.parquet        ship names, types, sizes (hourly)
data/winternav/date=2026-12-03/10_dirways.json.gz   icebreaker routes (hourly, raw)
data/winternav/date=2026-12-03/10_vessels.json.gz   icebreaker info (hourly, raw)

Query everything at once with DuckDB:

SELECT date, count(*) AS positions, count(DISTINCT mmsi) AS ships
FROM read_parquet('data/ais/*/*.parquet', hive_partitioning = true)
GROUP BY date ORDER BY date;

Setup (one time, about 10 minutes)

  1. Create a public GitHub repo called winter-navigation-ice and upload these files (public repos get unlimited free GitHub Actions minutes).
  2. Open the Actions tab, choose Collect winter navigation data → Run workflow. The first run creates the data branch. After that, it runs by itself every 10 minutes.
  3. If the push step fails with a permission error: Settings → Actions → General → Workflow permissions → Read and write permissions.

Working on your laptop

Step-by-step for Windows + VS Code: LOCAL_SETUP.md.

# Get the data into your Seafile folder (first time)
git clone --branch data --single-branch https://github.com/rislam21/winter-navigation-ice.git ~/Seafile/winter-nav-data
# Update it (e.g. weekly)
cd ~/Seafile/winter-nav-data && git pull

# Analyse
pip install -r requirements.txt
python src/analyze.py --data ~/Seafile/winter-nav-data/data --k 4

analyze.py cuts each ship's track into 1-hour segments and computes speed, stops, distance, straightness, turning and distance to the nearest icebreaker. It then clusters the segments into behaviour groups. Name the clusters by reading outputs/cluster_summary.csv.

Tests

pytest -q tests     # offline, uses fake API responses

Historical analysis (2006 → today)

The historical/ folder looks back over about 20 winters using free archives: FMI ice charts, EMODnet monthly vessel density and HELCOM yearly traffic maps. It also uses icebreaker season results. The question is whether harsh winters reduce shipping and make icebreaker waits longer. See historical/README.md.

Roadmap

  • Collector + automatic schedule
  • Behaviour segments + clustering
  • Historical scripts: winter severity 2006→, shipping density, icebreaker statistics
  • Run the historical analysis and publish the charts
  • Join ice thickness to every segment (by position and day)
  • Model: how much ice slows ships, by ship size/type
  • Live map (GitHub Pages, docs/map.html)
  • Project website (home, results, method & data, about) in docs/
  • Ice thickness layer on the live map
  • Dashboard: winter map of delays and bottlenecks

Data sources and licences

  • Ship positions, vessel metadata, winter navigation: Source: Fintraffic / digitraffic.fi, license CC 4.0 BY
  • Sea ice: Finnish Meteorological Institute via Copernicus Marine Service (free, registration required)
  • Historical traffic: EMODnet Human Activities vessel density (CC BY 4.0), HELCOM shipping traffic intensity

About

Open-data pipeline and live map of winter ship traffic in the Gulf of Bothnia: AIS + icebreaker + FMI ice data, DuckDB, clustering of ship behaviour in ice

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages