Categories
All Animations Maps OSGEO PostGIS QGIS Tutorials

My Strava Activities from the Same Place at the Same Time Animated

All of my activities from Strava if they started from the same place at the same time.

Strava Activites Animated

Longest activity time wise is an 11 hour walk.

Distance wise is a 200km helicopter ride.

Includes a couple of 100km cycles. But mainly walks on the beach, 5 km runs, and 10km cycles.

You can see the patterns from a number of locations that I have lived in.

How to

  1. Download your activities from Strava.
  2. Parse them into a PostgreSQL/PostGIS database with Python: https://github.com/HeikkiVesanto/StravaGarminParser/blob/master/parser_points_to_db.py
  3. Process the points to time series in the database: https://gist.github.com/HeikkiVesanto/3fbd55cda45394d069773a34ea244e4b
  4. Create animation in QGIS using the atlas generator.
Categories
All Animations Featured Ireland

Luas Map Compared to Real Geography

Inspired by /u/a_wandering_chemist on Reddit.

This is a look at how the map of the Dublin tram network, the Luas (Irish for speed), compares to the actual geographic footprint.

For a simpler view:

The processing of the transition is done in PostgreSQL with PostGIS, with the final animation in QGIS.

Categories
All Animations Scotland

Scotland’s Cartographic Outline

This is a topic I have covered in the past as well: Scotland’s Changing Outline

But the 1654 Blaeu Atlas of Scotland was an influential cartographic masterpiece. The National Library of Scotland have covered it’s publication history very well: The history behind the publication of the Blaeu Atlas of Scotland.

When the sixth volume of Joannis Blaeu’s Atlas Novus was released in 1655, the maps of Scotland formed one eighth of the total maps in his world atlas. Making Scotland one of the best mapped countries of the seventeenth-century world.

The animations include the following maps from the National Library of Scotland:

Blaeu Compared to Modern Day Outline from OpenStreetMap

Cycling Through the Maps by Publication Date

Blaeu – 1654
Sanson – 1665
Morden – 1687
Moll – 1714
Elphinstone – 1745
Dorret – 1751
Modern
Blaeu – 1654

Comparison to Modern Day In Between

Blaeu – 1654
Modern
Sanson – 1665
Modern
Morden – 1687
Modern
Moll – 1714
Modern
Elphinstone – 1745
Modern
Dorret – 1751
Modern
Blaeu – 1654

Comparison to Blaeu

Blaeu – 1654
Sanson – 1665
Blaeu – 1654
Morden – 1687
Blaeu – 1654
Moll – 1714
Blaeu – 1654
Elphinstone – 1745
Blaeu – 1654
Dorret – 1751
Blaeu – 1654

Overlaid

From: Scotland’s Changing Outline

Read about the maps here: Historic Maps of Scotland from Blaeu to Dorret (1600-1700)

Merch

There is also a t-shirt with all of the outlines overlaid, if you are a fan of Scottish cartographic history.

Categories
All Animations OpenStreetMap

Made With OpenStreetMap

Inspired by the “made with QGIS” logos by Klas Karlsson.

I made a few for OpenStreeMap ones. Well, I added some text to existing logos:

The simple OSM logo by ScubbX.

The main OSM logo by Ken Vermette.

Both logos are trademarked by the OSMF, but these are unofficial. For the full attribution and copyright guidelines visit the OpenStreetMap website.

Color:

License: CC BY-SA 3.0 Ken Vermette

PNG:

SVG:

Black:

License: CC BY-SA 2.0 ScubbX

PNG, clear background:

PNG, white background:

SVG:

White:

License: CC BY-SA 2.0 ScubbX

Example:

All buildings added to OSM in Ireland in 2021

Categories
All Animations Ireland Maps OpenStreetMap OSGEO

OpenStreetMap Ireland 2018 Visualized

2018 was a very productive year for OpenStreetMap in Ireland.

Around 70k nodes added, 60k ways added, and 160k polygons added.

Finally a company was formed to facilitate becoming a fully fledged local chapter.

What does that look like day to day:

Categories
All Animations Maps

Stanley Cup Champions Since 1915

Stanley Cup Champions Since 1915:

Average Location of Stanley Cup Champions Since 1915:

The average locations were created using a window function in PostgreSQL. We can utilise the geography type to take into account the curvature of the earth and make the calculation on a spheroid.

So for the average location of the last five years:

select id,
ST_Centroid(st_collect(geom)
over (ORDER BY id ROWS BETWEEN 4 PRECEDING AND CURRENT ROW)::geography,
True)::geometry as five_year_cent
from nhl.winner_1915
Categories
All Animations Ireland

GAA Winners 1887 to 2017 GIFs

Some of the outputs from my Data Driven Cartography workshop at the 2nd OSGeo Ireland conference.

Gaelic Football:

Final frame:
GAA football

Hurling:

Final frame:
GAA hurling

Categories
All Animations Ireland Maps OpenStreetMap

History of OpenStreetMap in Ireland

Last week I was invited to give a workshop at the Second Irish OSGeo Conference in Portlaoise. The event was a great success with a attendees from across the OSGeo space, from academics to startups.

I also volunteered to give a talk on OpenStreetMap (OSM) in Ireland. Since we are currently in the process of setting up an official chapter of OSM in Ireland. Check out OpenStreetmaMap.ie if you want to help.

Check out my full talk: here

But some of the visuals are more interesting than the talk as a whole.

To start out, the first edits in Ireland.

The first line:

Located in Banbridge, in Northern Ireland between Newry and Belfast:

First polygon:

Clearly St. Stephens Green, a great park in Dublin:

Then a look at the full history of roads in Ireland on OpenStreetMap:

 

A large part of the history of OpenStreetMap in Ireland is the townlands project. Townlands in Ireland are small divisions of land, often used in addressing for example. Your address could be: Mr. O’Brien, Blue house, Tawny (the townland), Donegal. The postman knows where you are.

There are over 61,000 townlands in Ireland. Traced manually from 650+ out of copyright OSi maps from Trinity College. Check out Townlands.ie for more info.

The project ran from 2012 to 2017 and the progress is clear when charting the history of boundaries in OpenStreetMap in Ireland:

 

And since the conference was held in Portlaoise, here is how it looks over time in OSM:

 

For the script to generate these histories see: Creating OpenStreetMap History Visualisations

Categories
All Animations Finland Maps

Finland 100 with 90 years of Finnish hockey

Finland is 100 years old today.

It has been a rich history. It is a young country, with myself being alive for almost a third of it.

In honour of #Finland100. Here is 90 years of Finnish hockey champions:

Starting with the 1927-1928 season with six teams the Finnish championship started with the SM-Sarja.
“S” for Suomen meaning Finnish.
“M” for Mestaruus meaning Championship
“Sarja” meaning series

The first year consisted of the following teams:
Viipurin Reipas – Viipuri Swift
HIFK – Sporting Society Comrades, Helsinki – Future 7 time champions
HJK – Helsinki Football Club – Future 3 time champions
KIF – Kruununhaka Sports Club (Helsinki) – Future 3 time champions
Tapa – Tampere Ballers – Future champions
HPS – Helsinki Ball Club

With ice hockey still being a very new sport in 1927 the victory went to Viipurin Reipas, primarily a football and bandy club. Located in Viipuri, a city which was lost to Russia after the Winter War.

At this stage ice hockey was purely an amateur sport, with sports clubs taking part in ice hockey as part of a larger program. Most often football in the summer and ice hockey in the winter, but also combined with other sports.

After Viipuri the championship went to Helsinki, with their football club. While no longer active in ice hockey they are still active in the highest level of Finnish football.

The Helsinki – Tampere fight for hockey championship was established early, with 1930-1930 seeing a standing of:
Helsinki 1
Tampere 1
Viipuri 1

The next few years also saw the Helsinki Figure Skating Club (HSK) win the championship, three times in total.

1939 to 1945 were crucial years for Finnish history. The war with Russia was one for the survival of Finland as a whole.
Some sacrifices had to be made.

The 1939-1940 season was completely called of for the Winter War. During which the captain of Tampere Ilves (3 time champions at the time, and 16 time champions all time) Jussi Tiitola was killed, among others.

The 1940–1941 season was played in between hostilities as an 8 team series.

1941–1942 was cancelled for the Continuation War.

1942–1943 was played as an 8 team series. With KIF winning their third championship in a row, discluding pauses for war.

The 1943–1944 season was started but a mass bombing of the Helsinki Kaisaniemi stadium called the season short. It was agreed that if Tampere Ilves (who had 0 losses at the time) could beat Tarmo and KIF they would be awarded the championship. They beat Tarmo, but unfortunately the transport connections between Tampere and Helsinki were bombed the day before the Ilves – KIF match. Thus the championship was never awarded.

The after war period saw a domination from the Tampere. With 18 championships in 24 years. With Ilves winning 11 and TBJ/Tappara winning 6 and KOO-VEE 1.

But notably champions from other cities aside from Helsinki and Tampere emerged.

Like TPS from Turku first champions in 1956, but future 11 time champions.

Tarmo (no longer active) from Hämeenlinna winning two in a row.

Lukko from Rauma winning their only championship so far in 1963, coming close in the future; with silver: 1961, 1966, 1988, and bronze: 1965, 1969, 1994, 1996, 2011, 2014.

And Pori, with RU-38 in 1967, Porin Karhut in 1965, and together as Porin Ässät (Pori Aces) in 1971.

While the SM-Series was mainly amateur it changed into the SM-Liiga in 1975, bringing with it a move to a professional sport.

This also introduced the playoffs to determine the overall champions. Also a relegation system was introduced, with teams coming last in the SM-Liiga facing relegation to a lower division and giving lower teams and opportunity for promotion.

The first championship outside of Southern Finland went to Oulu in 1981.

1985 was the latest championship for Ilves, their 16th in total.

Kärpät won again in 2004, and 2005 with back to back championships. With two more back to back championships to come.

With JYP from Jyväskylä winning in 2008 the total of cities with victories comes to 9.

The Ilves crown of 16 championships was met by Tappara (formerly TBK) in 2016, and beat in 2017 with back-to-back victories.

Here’s to another 100 years and more of hockey in Finland.

Categories
All Animations Featured OSGEO QGIS Tutorials

Storm Harvey QGIS Geometry Generator

Storm Harvey produced some extremely high levels of rainfall. Some areas of Texas received over 50 inches of rain over 9 days.

The National Oceanic and Atmospheric Administration (NOAA) provided some really great real time datasets to map the progress of the storm.

Among these were:
Hourly Precipitation
and
Hurricane Path

From these we can produce a GIF of hourly precipitation:

Hourly precipitation.

And total precipitation:
Hurricane Harvey Total Precipitation

Particularly the hurricane path was possible to create in QGIS using the Atlas Generator, and the excellent new:ish geometry generator. This can be found as an option for any layers symbology, as one of the renderers.

For my map I had a non spatial table that drove my atlas. This was a log table of all of the hours of precipitation I had loaded into my database. So I looped through each entry and showed the corresponding points of hourly precipitation for the corresponding hour. I also had hurricane path data as points for every 6 hours. So I could use the geometry generator to interpolate points in between known points.

While the query ended up being pretty long it is pretty straightforward.

It only needs to be run when the hour being generated does not end with a 00, 06, 12, or 18, because those are the positions I already know.

For the rest I need to generate two points. One for the previously known point, and one for the next known point.

Then I would create a line between those two points, measure the line, and place a point on the line x times one sixth of the way for the start of the line depending on the hour from the last known point.

Overall I am very impressed and happy with the result. With a bit of data defined rotation the storm progress looks great.

line_interpolate_point(
Make_line(
geometry(
case when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('00', '06', '12', '18') then
    get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') )
else
    get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - (attribute(  @atlas_feature , 'id') % 100 % 6  ))
end)
,
geometry(
case
    when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('00', '06', '12') then
        get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') + 6 )
    when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('18') then
        get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') + 100 - 18 )
    when to_int(right(to_string(attribute(@atlas_feature , 'id')),2)) > 18 then
        get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - ((attribute(  @atlas_feature , 'id') % 100 % 6)  ) + 100 - 18)
    else
        get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - ((attribute(  @atlas_feature , 'id') % 100 % 6)  ) + 6)
end)
),
length(Make_line(geometry(
case when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('00', '06', '12', '18') then get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') )
else get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - (attribute(  @atlas_feature , 'id') % 100 % 6  ))
end
)
,
geometry(
case
    when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('00', '06', '12') then
        get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') + 6 )
    when right(to_string(attribute(@atlas_feature , 'id')),2) IN ('18') then
        get_feature(  @layer_name , 'dtg', attribute(  @atlas_feature , 'id') + 100 - 18 )
    when to_int(right(to_string(attribute(@atlas_feature , 'id')),2)) > 18 then
        get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - ((attribute(  @atlas_feature , 'id') % 100 % 6)  ) + 100 - 18)
    else
        get_feature(  @layer_name , 'dtg',  attribute(  @atlas_feature , 'id') - ((attribute(  @atlas_feature , 'id') % 100 % 6)  ) + 6)
end)))
*
((attribute(  @atlas_feature , 'id') % 100 % 6) * 0.16666666666666666))