# Personal Heatmaps

DevFeed: [Personal Heatmaps](<https://devfeed.tech/articles/personal-heatmaps-26574.md>)

Original publisher: [Read original article](<https://medium.com/strava-engineering/personal-heatmaps-f51d15a0db2b?source=rss----89d4108ce2a3---4>)

Author: J Evans

Published: 2022-10-28T21:15:46Z

Content type: tutorial

Language: en

Sources: [Strava Engineering](<https://devfeed.tech/sources/strava-engineering.md>)

Topics: [data](<https://devfeed.tech/topics/data.md>), [Algorithm](<https://devfeed.tech/topics/algorithm.md>), [navigation](<https://devfeed.tech/topics/navigation.md>), [pixel](<https://devfeed.tech/topics/pixel.md>), [real-time](<https://devfeed.tech/topics/real-time.md>), [Google Maps](<https://devfeed.tech/topics/google-maps.md>), [Website](<https://devfeed.tech/topics/website.md>)

Tags: [algorithm](<https://devfeed.tech/tags/algorithm.md>), [cycling](<https://devfeed.tech/tags/cycling.md>), [data](<https://devfeed.tech/tags/data.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [gis](<https://devfeed.tech/tags/gis.md>), [google-maps](<https://devfeed.tech/tags/google-maps.md>), [gps](<https://devfeed.tech/tags/gps.md>), [heat](<https://devfeed.tech/tags/heat.md>), [map](<https://devfeed.tech/tags/map.md>), [mapping](<https://devfeed.tech/tags/mapping.md>), [navigation](<https://devfeed.tech/tags/navigation.md>), [pixel](<https://devfeed.tech/tags/pixel.md>), [real-time](<https://devfeed.tech/tags/real-time.md>), [recursion](<https://devfeed.tech/tags/recursion.md>), [running](<https://devfeed.tech/tags/running.md>), [strava](<https://devfeed.tech/tags/strava.md>), [zoom](<https://devfeed.tech/tags/zoom.md>)

## AI overview

This article explains the algorithm behind Strava's Personal Heatmap, which renders an athlete's GPS activity as a frequency-based heatmap on an interactive world map. It focuses on Mercator projection and recursive map tiling, where 256x256 pixel tiles are served at different zoom levels for real-time navigation.

## Source excerpt

This post discusses the algorithm behind Personal Heatmap, one of Strava's most acclaimed subscriber features. Product Overview The Personal Heatmap feature has been around in some form since 2015, but we gave it a major overhaul in 2020. For those unfamiliar, the heatmap is an aggregated view of an athlete's GPS-enabled activities on Strava. Activity data is rendered onto a map according to path traversal frequency; the more an athlete runs on a road, the brighter -- i.e. "hotter" -- that road shows up on the map. The result is a beautiful color gradient displaying the intricate web of past activities, unique to each athlete. The Personal Heatmap is displayed on an interactive world map, also known as a slippy map. Athletes can seamlessly zoom in and out or pan around to arbitrary views of the map, and their activity heat stays displayed the entire time. To enable this, we must provide a scheme for rendering and serving subsections of the world map on the fly. Enter map tiling. Mercator Projection & Map Tiling Map tiling is the practice of subdividing a map into many discrete images that can be stitched together and rendered as a single image in real-time during map navigation. The first step in choosing a tiling scheme is picking what world map to use. Enter, the Mercator Projection, the most commonly used projection of Earth as a flat, rectangular surface. We use this projection in all of our mapping products, including heatmaps. https://medium.com/media/d9e120d13950dd0f1bb4ee14108aa9a9/href Now, imagine a grid overlaying the Mercator projection. Each grid section is known as a tile, a pixel image with resolution 256x256. Every tile has an associated zoom level, and tiles are defined recursively according to this zoom level. A tile at a given zoom level can be subdivided into four equal sized tiles at a next zoom level. For example, Zoom level 0 displays the entire planet in a single 256x256 pixel image. Zoom level 1 displays the world in four 256x256 pixel images.