<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>cycleways - Jake Coppinger</title>
	<atom:link href="https://jakecoppinger.com/tag/cycleways/feed/" rel="self" type="application/rss+xml" />
	<link>https://jakecoppinger.com</link>
	<description>Jake Coppinger&#039;s blog and portfolio.</description>
	<lastBuildDate>Wed, 17 Jan 2024 02:06:27 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.8.5</generator>

<image>
	<url>https://jakecoppinger.com/wp-content/uploads/2024/07/cropped-closeup-headshot-jake-coppinger-2024-32x32.jpg</url>
	<title>cycleways - Jake Coppinger</title>
	<link>https://jakecoppinger.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Which Australian councils are building the most cycleways?</title>
		<link>https://jakecoppinger.com/2024/01/which-australian-councils-are-building-the-most-cycleways/</link>
					<comments>https://jakecoppinger.com/2024/01/which-australian-councils-are-building-the-most-cycleways/#respond</comments>
		
		<dc:creator><![CDATA[Jake C]]></dc:creator>
		<pubDate>Tue, 16 Jan 2024 22:55:45 +0000</pubDate>
				<category><![CDATA[Cycling]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Maps]]></category>
		<category><![CDATA[Side project]]></category>
		<category><![CDATA[Streets]]></category>
		<category><![CDATA[Urbanism]]></category>
		<category><![CDATA[australian]]></category>
		<category><![CDATA[councils]]></category>
		<category><![CDATA[cycleways]]></category>
		<category><![CDATA[cycling]]></category>
		<category><![CDATA[openstreetmap]]></category>
		<category><![CDATA[OSM]]></category>
		<category><![CDATA[paths]]></category>
		<category><![CDATA[shared]]></category>
		<guid isPermaLink="false">https://jakecoppinger.com/?p=1082</guid>

					<description><![CDATA[<p>Australian Cycleway Stats is a dashboard that provides an in-depth look at the kilometres of cycleways and safe streets in every Australian council, encompassing current, under-construction, and proposed projects, as well as international benchmarks.</p>
<p>The post <a href="https://jakecoppinger.com/2024/01/which-australian-councils-are-building-the-most-cycleways/">Which Australian councils are building the most cycleways?</a> first appeared on <a href="https://jakecoppinger.com">Jake Coppinger</a>.</p>]]></description>
										<content:encoded><![CDATA[<p><a href="https://australiancyclewaystats.jakecoppinger.com/" target="_blank" rel="noopener" title="">Australian Cycleway Stats</a> is a dashboard that provides an in-depth look at the kilometres of cycleways and safe streets in every Australian council, encompassing current, under-construction, and proposed projects, as well as international benchmarks. It utilises <a href="https://www.openstreetmap.org/about" target="_blank" rel="noopener" title="">OpenStreetMap</a> data which has an <a href="https://wiki.openstreetmap.org/wiki/Key:cycleway" target="_blank" rel="noopener" title="">extremely detailed</a> specification for cycleway types to differentiate between separated cycleways, shared paths and on street &#8220;door zone&#8221; lanes.</p>



<figure class="wp-block-image size-large"><a href="https://australiancyclewaystats.jakecoppinger.com/"><img fetchpriority="high" decoding="async" width="1024" height="1010" src="https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-1024x1010.png" alt="" class="wp-image-1084" srcset="https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-1024x1010.png 1024w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-300x296.png 300w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-768x758.png 768w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-1536x1515.png 1536w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-top-2048x2020.png 2048w" sizes="(max-width: 1024px) 100vw, 1024px" /></a></figure>



<figure class="wp-block-image alignwide size-large"><a href="https://australiancyclewaystats.jakecoppinger.com/"><img decoding="async" width="1024" height="687" src="https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-1024x687.png" alt="" class="wp-image-1085" srcset="https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-1024x687.png 1024w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-300x201.png 300w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-768x515.png 768w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-1536x1030.png 1536w, https://jakecoppinger.com/wp-content/uploads/2024/01/cycleway-stats-aus-table-2048x1373.png 2048w" sizes="(max-width: 1024px) 100vw, 1024px" /></a></figure>



<p>I built it to quickly compare and contrast Australian cities with their international counterparts. Clicking on any statistic opens an Overpass Turbo query displaying the relevant data.</p>



<figure class="wp-block-image alignwide size-large"><img decoding="async" width="1024" height="687" src="https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-1024x687.png" alt="" class="wp-image-1086" srcset="https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-1024x687.png 1024w, https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-300x201.png 300w, https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-768x515.png 768w, https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-1536x1030.png 1536w, https://jakecoppinger.com/wp-content/uploads/2024/01/overpass-sydney-cycleways-2048x1373.png 2048w" sizes="(max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption">Map displayed after clicking on the length of separated cycleways in the City of Sydney council</figcaption></figure>



<p>I previously wrote a blog post on turn-by-turn bicycle navigation apps that use this data at <a href="https://jakecoppinger.com/2020/07/the-best-apps-for-bicycle-directions/" target="_blank" rel="noopener" title="The Best Apps for Bicycle Directions (2020)">The Best Apps for Bicycle Directions (2020)</a>.</p>



<h1 class="wp-block-heading">Architecture</h1>



<p>The website is a simple frontend React Typescript app, however the data is statically compiled into a large JSON blob.</p>



<p>Generating the JSON blob requires thousands of Overpass Turbo requests. These requests are cached at build time on the filesystem using a hash of the query string as a key. This currently requires clearing the cache to completely regenerate data to fetch new updates from OpenStreetMap. When generating data for Australian councils I use a self-hosted Overpass server (also improving speed dramatically), while using overpass-api.de for the few international examples.</p>



<p>I could achieve a faster first paint by async loading this JSON blob at runtime but I haven&#8217;t yet implemented this.</p>



<p>Population counts are sourced from <a href="https://www.wikidata.org/wiki/Wikidata:Introduction" target="_blank" rel="noopener" title="">Wikidata</a> (and pregenerated in the JSON blob) based on the <code>wikidata</code> tag on OpenStreetMap relations.</p>



<p>When area names have a non-english name (identified by a <code>name:en</code> tag present), both English and local names are displayed.</p>



<h1 class="wp-block-heading">Overpass queries</h1>



<p>Overpass queries are written in <a href="https://github.com/jakecoppinger/australian-cycleway-stats/blob/main/static-backend/src/utils/overpass-queries.ts">https://github.com/jakecoppinger/australian-cycleway-stats/blob/main/static-backend/src/utils/overpass-queries.ts</a> and are somewhat complex. They contain some &#8220;opinionated&#8221; tradeoffs (informed by policy) in what roads are considered safe (&lt;= 30kmh) and what is considered a dedicated and shared cycle path. Improvements or questions are welcome!</p><p>The post <a href="https://jakecoppinger.com/2024/01/which-australian-councils-are-building-the-most-cycleways/">Which Australian councils are building the most cycleways?</a> first appeared on <a href="https://jakecoppinger.com">Jake Coppinger</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://jakecoppinger.com/2024/01/which-australian-councils-are-building-the-most-cycleways/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Creating aerial imagery with a bike helmet camera (GoPro) and OpenDroneMap</title>
		<link>https://jakecoppinger.com/2022/12/creating-aerial-imagery-with-a-bike-helmet-camera-and-opendronemap/</link>
					<comments>https://jakecoppinger.com/2022/12/creating-aerial-imagery-with-a-bike-helmet-camera-and-opendronemap/#comments</comments>
		
		<dc:creator><![CDATA[Jake C]]></dc:creator>
		<pubDate>Sat, 10 Dec 2022 09:08:15 +0000</pubDate>
				<category><![CDATA[Cycling]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Side project]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[Urbanism]]></category>
		<category><![CDATA[360 degree camera]]></category>
		<category><![CDATA[bike]]></category>
		<category><![CDATA[cycleways]]></category>
		<category><![CDATA[cycling]]></category>
		<category><![CDATA[gopro]]></category>
		<category><![CDATA[helmet]]></category>
		<category><![CDATA[openaerialmap]]></category>
		<category><![CDATA[opendronemap]]></category>
		<category><![CDATA[openstreetmap]]></category>
		<category><![CDATA[orthoimagery]]></category>
		<category><![CDATA[OSM]]></category>
		<category><![CDATA[photogrammetry]]></category>
		<category><![CDATA[spherical]]></category>
		<guid isPermaLink="false">https://jakecoppinger.com/?p=293</guid>

					<description><![CDATA[<p>This technical guide details how you can create your own orthorectified (aka satellite view/bird mode) imagery, point clouds and 3D models of streets with nothing but a 360 degree camera mounted on bicycle helmet, and the open source photogrammetry software OpenDroneMap.</p>
<p>The post <a href="https://jakecoppinger.com/2022/12/creating-aerial-imagery-with-a-bike-helmet-camera-and-opendronemap/">Creating aerial imagery with a bike helmet camera (GoPro) and OpenDroneMap</a> first appeared on <a href="https://jakecoppinger.com">Jake Coppinger</a>.</p>]]></description>
										<content:encoded><![CDATA[<p><em>See comments on <a href="https://news.ycombinator.com/item?id=33947618" target="_blank" rel="noopener" title="Hacker News (#3, 11 comments)">Hacker News (24 comments, 220 points)</a></em></p>



<p>This technical guide details how you can create your own orthorectified (aka satellite view/<a href="https://twitter.com/btaylor/status/1099370126678253569" target="_blank" rel="noopener" title="">bird mode</a>) imagery, point clouds and 3D models of streets with nothing but a 360 degree camera mounted on bicycle helmet, and the open source photogrammetry software <a href="https://opendronemap.org/" target="_blank" rel="noopener" title="">OpenDroneMap</a>.</p>



<figure class="wp-block-image alignwide size-large"><img loading="lazy" decoding="async" width="1024" height="772" src="https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-1024x772.jpg" alt="" class="wp-image-356" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-1024x772.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-300x226.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-768x579.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-1536x1158.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/blender-perspective-2048x1544.jpg 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>Why might you want to do this? With your own up-to-date and highly detailed orthorectified imagery you could:</p>



<ul class="wp-block-list"><li>quantify and communicate inefficient road space allocation</li><li>record necessary infrastructure repairs</li><li>take measurements such as lane and cycleway widths</li><li>measure footpath obstructions in 3D and rate pedestrian amenity</li><li>map kerb features on OpenStreetMap</li><li>survey street parking using the new OSM spec: <a href="https://wiki.openstreetmap.org/wiki/Street_parking" target="_blank" rel="noopener" title="">wiki.openstreetmap.org/wiki/Street_parking</a></li><li>3D print a model of your home street!</li></ul>


<div id="mc_embed_shell"><style type="text/css">
        #mc_embed_signup{background:#fff; false;clear:left; font:14px Helvetica,Arial,sans-serif; width: 600px;}<br />
        /* Add your own Mailchimp form style overrides in your site stylesheet or in this style block.<br />
           We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */<br />
</style>
<div id="mc_embed_signup"><form id="mc-embedded-subscribe-form" class="validate" action="https://jakecoppinger.us17.list-manage.com/subscribe/post?u=3c1bd4fc8fca6648af03e916a&amp;id=ad49243f2c&amp;f_id=00d3e4e3f0" method="post" name="mc-embedded-subscribe-form" target="_blank">
<div id="mc_embed_signup_scroll">
<h2><a href="http://eepurl.com/hemS9j" target="_blank" rel="noopener">Subscribe to Jake&#8217;s blog</a></h2>
Email notifications of new blog posts are infrequent, brief, and plain text.

</div>
</form></div>
</div>


<iframe style="width:100%;max-width:100%;height:70vh" src="https://sketchfab.com/models/85937287d282425c86cd53ae85fbec35/embed?autostart=1" class=" alignfull" frameborder="0"></iframe>



<p></p>



<figure class="wp-block-image alignwide size-large"><img loading="lazy" decoding="async" width="1024" height="738" src="https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-1024x738.png" alt="" class="wp-image-355" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-1024x738.png 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-300x216.png 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-768x553.png 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-1536x1107.png 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/id-editor-portman-st-2048x1476.png 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption>Viewing orthoimagery generated with a GoPro in the OpenStreetMap ID editor</figcaption></figure>



<figure class="wp-block-video alignwide"><video controls src="https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cyclepath-v2.mp4"></video><figcaption>Making measurements in WebODM. Generating 2d elevation profiles is also possible.</figcaption></figure>



<p>Drones are great for surveying and mapping things on the kerb (parking/public space/road widths/building shadows) but there are a lot of places you can&#8217;t fly a drone.</p>



<p><a href="https://opendronemap.org/" target="_blank" rel="noopener" title="">OpenDroneMap</a> is usually used to combine a set of geotagged drone images into one coherent 3d model, but it can also be used with <em>any</em> geotagged images.</p>



<p>Roughly the process is as follows:</p>



<ul class="wp-block-list"><li>Take spherical images on a 360 degree camera</li><li>Import the files from the camera</li><li>Optional: Convert the photos into rectangular, spherical images (for GoPro: convert from the proprietary GoPro format to standard spherical images using GoPro Fusion v1.2)</li><li>Start/login to WebODM, upload the images <em>with fisheye lens setting</em> for 180 degree images or <em>spherical</em> for rectangular 360 degree images and generate imagery &amp; model</li></ul>



<p>Please comment any projects you make after reading this guide, or if you have any questions! There are certainly issues with this process with I&#8217;ve added under Limitations.</p>



<h1 class="wp-block-heading">Table of Contents</h1>



<div class="wp-block-aioseo-table-of-contents"><ul><li><a href="#aioseo-aquiring-a-camera">Buying a 360 degree camera</a></li><li><a href="#aioseo-gopro-fusion-specific-tips">GoPro Fusion specific tips</a></li><li><a href="#aioseo-downloading-the-images">Preprocessing the images</a></li><li><a href="#aioseo-generating-the-model-and-orthorectified-imagery-with-web-opendronemap">Generating the model and orthorectified imagery with Web OpenDroneMap</a><ul><li><a href="#aioseo-setting-up-webodm">Setting up WebODM locally</a></li><li><a href="#aioseo-optional-adding-webodm-lightening-as-a-processing-node">Optional: Adding WebODM lightening as a processing node</a></li><li><a href="#aioseo-generating-the-model">Generating the model &#038; selecting the correct options</a></li><li><a href="#aioseo-output-accuracy-taking-measurements">Output accuracy: taking measurements</a></li></ul></li><li><a href="#aioseo-optional-create-equirectangular-photos-rather-than">Alternative: Generating and processing equirectangular spherical images</a></li><li><a href="#aioseo-limitations">Limitations</a></li><li><a href="#aioseo-appendix-things-that-didnt-work">Appendix: Things that didn&#8217;t work</a><ul><li><a href="#aioseo-removing">Removing helmet artifacts by cropping</a></li><li><a href="#aioseo-removing-helmet-artifacts-by-adding-a-mask">Removing helmet artifacts by adding a mask</a></li></ul></li><li><a href="#aioseo-further-research-to-be-done">Further research/experimentation</a></li><li><a href="#aioseo-prior-art">Prior art</a></li></ul></div>



<h2 class="wp-block-heading" id="aioseo-aquiring-a-camera">Buying a 360 degree camera</h2>



<p>360 degree cameras can be very expensive (the ones mounted on Google Street View cars are <a href="https://www.quora.com/How-much-does-Google-Street-View-cost-Google-to-operate" target="_blank" rel="noopener" title="">possibly $45,000!</a>), but GoPro makes <em>relatively</em> affordable models. See <a href="https://help.mapillary.com/hc/en-us/articles/115001465989-About-360-cameras" target="_blank" rel="noopener" title="">https://help.mapillary.com/hc/en-us/articles/115001465989-About-360-cameras</a> for more suitable cameras. One common second hand (and now unsupported) model is the GoPro Fusion, which I&#8217;ll base this guide on.</p>



<p>Note: Seth Deegan has written a PowerShell script for using Insta360 cameras with ODM. I haven&#8217;t tried it but it seems worth a look: <a href="https://github.com/lectrician1/Insta360-2-ODM" target="_blank" rel="noopener" title="">https://github.com/lectrician1/Insta360-2-ODM</a></p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="872" height="1024" src="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm-872x1024.png" alt="" class="wp-image-303" srcset="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm-872x1024.png 872w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm-255x300.png 255w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm-768x902.png 768w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm-1308x1536.png 1308w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-11.09.23-pm.png 1328w" sizes="auto, (max-width: 872px) 100vw, 872px" /></figure>



<p>To generate a detailed model you will need to capture enough images close together. You could mount it to the top of your car, but unless you bought an expensive elevated mount much of the image would just be your car roof!</p>



<p>Some advantages of taking imagery from a bicycle:</p>



<ul class="wp-block-list"><li>The unobstructed field of view is larger so ODM gets more data for a better model</li><li>The average speed is lower permitting more photos (the maximum self timer frequency of this camera is 2 shots/second)</li><li>You can capture images from different places in the street for more data, such as the road, footpath and bike lanes</li><li>If you&#8217;re putting in this much effort to study public space and urban planning you probably like bikes <img src="https://s.w.org/images/core/emoji/16.0.1/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></li></ul>



<p>You&#8217;ll need to buy a helmet mount for the GoPro or your chosen camera. GoPro makes a bicycle helmet mount: <a href="https://gopro.com/en/us/shop/mounts-accessories /vented-helmet-strap-mount/GVHS30.html" target="_blank" rel="noopener" title="">https://gopro.com/en/us/shop/mounts-accessories /vented-helmet-strap-mount/GVHS30.html</a> (though many non-branded mounts exist on eBay/Amazon too). Be aware a camera mounted on a bicycle helmet is possibly a safety risk to yourself if you crash &#8211; be careful.</p>



<p>If you have the ability to mount the camera on a long pole above your head, this will increase the unobstructed field of view and improve the perspective of the street which will improve the results. I imagine this would attract even more attention! If you have tips for building rigs like this please leave a comment. Andrew Harvey wrote an OpenStreetMap diary entry on his setup here: <a href="https://www.openstreetmap.org/user/aharvey/diary/42139" target="_blank" rel="noopener" title="">https://www.openstreetmap.org/user/aharvey/diary/42139</a></p>



<h2 class="wp-block-heading" id="aioseo-gopro-fusion-specific-tips">GoPro Fusion specific tips</h2>



<p>Set the camera to:</p>



<ul class="wp-block-list"><li>Timelapse photo mode (icon of camera &amp; timer circle)</li><li>Image frequency to 0.5 seconds</li><li>Enable GPS geotagging</li></ul>



<p>Mount the camera to the helmet, wait until the GPS location icon turns solid, and start capturing! Sometimes the first few shots don&#8217;t have any location in the EXIF data but this doesn&#8217;t seem to confuse WebODM, you can check this with <code>identify -verbose image</code> or your metadata viewer of choice.</p>



<h1 class="wp-block-heading" id="aioseo-downloading-the-images">Preprocessing the images</h1>



<p>The GoPro Fusion will output two 180 degree &#8220;fisheye&#8221; images to two separate SD cards. Copy all these images to a folder onto your computer.</p>



<figure class="wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex">
<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="2560" height="2474" data-id="359" src="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-scaled.jpg" alt="" class="wp-image-359" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-scaled.jpg 2560w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-300x290.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-1024x990.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-768x742.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-1536x1485.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277-2048x1979.jpg 2048w" sizes="auto, (max-width: 2560px) 100vw, 2560px" /></figure>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="2560" height="2474" data-id="358" src="https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-scaled.jpg" alt="" class="wp-image-358" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-scaled.jpg 2560w, https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-300x290.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-1024x990.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-768x742.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-1536x1485.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/GF010277-2048x1979.jpg 2048w" sizes="auto, (max-width: 2560px) 100vw, 2560px" /></figure>
<figcaption class="blocks-gallery-caption">Front and back images</figcaption></figure>



<p>For an alternate method, see instructions under the generating equirectangular image heading.</p>



<p>Unfortunately, only the &#8220;front&#8221; images have geotagged information, so you&#8217;ll need to copy the exif data from each &#8220;back&#8221; image to each similarly named &#8220;front&#8221; image.</p>



<p>A quick and dirty way of doing this is generating a list of terminal commands, that copies all exif tags from each &#8220;front&#8221; to each &#8220;back&#8221; photo:</p>



<p><code>ls -l | grep "GF" | sed -E "s/^.* GF(.*).JPG*/exiftool −overwrite_original_in_place -gps:all -tagsFromFile GF\1.JPG GB\1.JPG/g" &gt; script.sh</code></p>



<p>I&#8217;m sure there are better and easier ways of doing this, please let me know if you come up with one.</p>



<h1 class="wp-block-heading" id="aioseo-generating-the-model-and-orthorectified-imagery-with-web-opendronemap">Generating the model and orthorectified imagery with Web OpenDroneMap</h1>



<p>WebODM (<a href="https://opendronemap.org/" target="_blank" rel="noreferrer noopener">https://opendronemap.org</a>) is an absolute marvel of open source engineering. Unfortunately, generating 3D models takes some serious computing horsepower. You can either use the paid cloud version (WebODM Lightening) at <a href="https://webodm.net/" target="_blank" rel="noopener" title="">https://webodm.net/</a> (fast) or run the software on your own computer (a few hours/overnight/days depending on the number of images).</p>



<p>You can directly upload images to WebODM Lightening to process, however you don&#8217;t get some friendly/useful features like a browsable map and 3d model viewer. I recommend setting up WebODM locally and adding WebODM Lightening as a &#8220;processing node&#8221;, so you get the power of the cloud and the extra features of WebODM.</p>



<h2 class="wp-block-heading" id="aioseo-setting-up-webodm">Setting up WebODM locally</h2>



<p>Running the software using Docker is a breeze. Install Docker from <a href="https://www.docker.com/" target="_blank" rel="noopener" title="">https://www.docker.com/</a> (or your preferred method), allocate as much memory &amp; CPUs as you can, and then:</p>



<pre class="wp-block-code"><code>git clone https://github.com/OpenDroneMap/WebODM --config core.autocrlf=input --depth 1
cd WebODM
./webodm.sh start </code></pre>



<p>See <a href="https://github.com/OpenDroneMap/WebODM#getting-started" target="_blank" rel="noopener" title="">https://github.com/OpenDroneMap/WebODM#getting-started</a> more more details including GPU acceleration.</p>



<p>You&#8217;ll now be able to open WebODM on <a href="http://localhost:8000" target="_blank" rel="noopener" title="">http://localhost:8000</a></p>



<h2 class="wp-block-heading" id="aioseo-optional-adding-webodm-lightening-as-a-processing-node">Optional: Adding WebODM lightening as a processing node</h2>



<p>Click lightening network in your WebODM sidebar and login.</p>



<h2 class="wp-block-heading" id="aioseo-generating-the-model">Generating the model &amp; selecting the correct options</h2>



<p>Add a new project, click &#8220;Select images &amp; GCP&#8221;, select your images, then you will see options for processing your imagery. If you&#8217;re using WebODM Lightening, make sure to set the Processing Node appropriately.</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="421" src="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.30.39-pm-1024x421.png" alt="" class="wp-image-296" srcset="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.30.39-pm-1024x421.png 1024w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.30.39-pm-300x123.png 300w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.30.39-pm-768x316.png 768w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.30.39-pm.png 1368w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p></p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="759" src="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm-1024x759.png" alt="" class="wp-image-300" srcset="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm-1024x759.png 1024w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm-300x222.png 300w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm-768x569.png 768w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm-1536x1139.png 1536w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.47.37-pm.png 1538w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>Some options I&#8217;ve found are required:</p>



<p>If you are using the raw 180 degree &#8220;fisheye&#8221; images straight out of the GoPro Fusion, set <code>camera-lens</code> to <strong>fisheye</strong> (this is critical). If you are using equirectangular images set to <code><strong>spherical</strong></code>. WebODM seems to be unable to auto-identify the lens type in both cases.</p>



<ul class="wp-block-list"><li>enable <code>sky removal</code> &#8211; this uses AI to mask out the sky in each frame so that there are less artifacts in the final model</li><li>enable <code>auto-boundary</code></li><li>enable <code>bg-removal</code></li></ul>



<p>This is just from my trial and error, there may be better option configurations.</p>



<p>You will likely need to enable &#8220;resize images&#8221; to 2000px or it is very easy to run out of memory.</p>



<p>Though it is out of scope for this article, you can also set up a VPS instance to speed up the process if you don&#8217;t want to use the hosted cloud processing tool. Ive tried this, but it&#8217;s probably more effort than it&#8217;s worth unless you&#8217;re making a business out of this.</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="619" src="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-1024x619.png" alt="" class="wp-image-297" srcset="https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-1024x619.png 1024w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-300x181.png 300w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-768x464.png 768w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-1536x929.png 1536w, https://jakecoppinger.com/wp-content/uploads/2022/11/Screen-Shot-2022-11-17-at-10.33.27-pm-2048x1238.png 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption>64 cores and 124GB of RAM!</figcaption></figure>



<p>Even with an EC2 instance with 124GB of RAM and 324 images at 5760 × 2180 pixels I ran out of memory &#8211; remember to enable some swap space if you want to run at full size: <a href="https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-18-04" target="_blank" rel="noopener" title="">https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-18-04</a></p>



<h2 class="wp-block-heading" id="aioseo-output-accuracy-taking-measurements">Output accuracy: taking measurements</h2>



<p>OpenDroneMap can make measurements of the 3D model. I&#8217;ve found these are usually quite accurate; they may have small &#8220;measurement&#8221; errors due to artifacts or distortion but will tend towards the correct value &#8211; GPS coordinates ensure the scale is correct.</p>



<p>For example, measuring the width of the green paint of the cycle path:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="699" src="https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-1024x699.jpg" alt="" class="wp-image-378" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-1024x699.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-300x205.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-768x524.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-1536x1049.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cycle-path-compressed-2048x1399.jpg 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p></p>



<figure class="wp-block-gallery alignwide has-nested-images columns-default is-cropped wp-block-gallery-2 is-layout-flex wp-block-gallery-is-layout-flex">
<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="857" data-id="381" src="https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1-1024x857.jpg" alt="" class="wp-image-381" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1-1024x857.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1-300x251.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1-768x643.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1-1536x1286.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/large-path-1.jpg 2000w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="768" data-id="380" src="https://jakecoppinger.com/wp-content/uploads/2022/12/small-path-1024x768.jpg" alt="" class="wp-image-380" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/small-path-1024x768.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/small-path-300x225.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/small-path-768x576.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/small-path-1536x1152.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/small-path.jpg 2000w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>
</figure>



<p>Large path:</p>



<ul class="wp-block-list"><li>OpenDroneMap: 4.54 metres</li><li>Tape measure: 4.56 metres</li></ul>



<p>Small path:</p>



<ul class="wp-block-list"><li>OpenDroneMap: 1.89 metres (though this varies slightly due to distortions)</li><li>Tape measure: 1.89 metres</li></ul>



<p></p>



<h1 class="wp-block-heading" id="aioseo-optional-create-equirectangular-photos-rather-than">Alternative: Generating and processing equirectangular spherical images</h1>



<p>I&#8217;m currently unclear whether this method is faster or produces better results than the raw 180 degree images. I&#8217;m very interested to hear if you have experience (and I&#8217;ll update this if I get more evidence). I believe the GroPro Max generates these images <em>in camera</em>, so this won&#8217;t be required.</p>



<p>If you use the GoPro Fusion, unfortunately because this camera is no longer supported GoPro discontinued the software: <a href="https://gopro.com/en/au/news/fusion-end-of-life" target="_blank" rel="noopener" title="">https://gopro.com/en/au/news/fusion-end-of-life</a></p>



<p>You&#8217;ll (unfortunately) need to use the proprietary GoPro Fusion software to generate spherical images. I&#8217;ve found on an M1 Mac (Monterey) the only version that still runs is 1.2, 1.4 just crashes. The least dodgy download I can find is <a href="https://macdownload.informer.com/fusion-studio/1.2/" target="_blank" rel="noopener" title="">https://macdownload.informer.com/fusion-studio/1.2/</a>.</p>



<p>If you make an open source solution (maybe building from <a href="https://stackoverflow.com/questions/37796911/is-there-a-fisheye-or-dual-fisheye-to-equirectangular-filter-for-ffmpeg" target="_blank" rel="noopener" title="">https://stackoverflow.com/questions/37796911/is-there-a-fisheye-or-dual-fisheye-to-equirectangular-filter-for-ffmpeg</a>) please let me know! Edit: Looks like this repo will do it. <a href="https://github.com/trek-view/fusion2sphere" target="_blank" rel="noopener" title="">https://github.com/trek-view/fusion2sphere</a></p>



<p>This camera has two SD card slots &#8211; one for the front facing camera, and one for the back facing camera. Sometimes only one camera works for part of the shoot and the proprietary software refuses to stitch any of the photos at all! The only way I&#8217;ve found to combat this is to format the card in camera before each shoot. Spending more on a GoPro Max may solve a lot of headaches!</p>



<h1 class="wp-block-heading" id="aioseo-limitations">Limitations</h1>



<p>Little helmets appear! I&#8217;ve tried some techniques but haven&#8217;t found a proper solution that doesn&#8217;t degrade the model/orthophoto structure.</p>



<h1 class="wp-block-heading" id="aioseo-appendix-things-that-didnt-work">Appendix: Things that didn&#8217;t work</h1>



<h2 class="wp-block-heading" id="aioseo-removing">Removing helmet artifacts by cropping</h2>



<p>I tried using the <code>convert</code> and <code>mogrify</code> tools (part of the amazing open source <code>ImageMagick</code> suite) can crop the spherical photos <em>and retain the geographical information!</em> The cropping works great, but OpenDroneMap doesn&#8217;t seem to be able to understand a cropped equirectangular image. If you&#8217;d like to try to get this working, here are the steps I took.</p>



<p>First install ImageMagick (<code>sudo apt-get install imagemagick</code> on Linux/<code>brew install imagemagick</code> on macOS).</p>



<p>The general syntax is:<br><code>convert -crop {x_size}x{y_size}+{x_offset}+{y_offset} inputfile outputfile</code></p>



<p>See <a href="https://deparkes.co.uk/2015/04/30/batch-crop-images-with-imagemagick/" target="_blank" rel="noopener" title="">https://deparkes.co.uk/2015/04/30/batch-crop-images-with-imagemagick/</a> for more detail and helpful diagrams.</p>



<p>Helpfully, the helmet artifact is always at the bottom of frame, so the x offset and y offset will be zero.</p>



<p>To crop 700 pixels off the bottom of a spherical image, you can use</p>



<p><code>convert -crop 5760x"$((2880-700))"+0+0 inputfile output</code>file</p>



<p>To batch convert a number of files, where the input files are in <code>./input/</code>, and you have made an output directory <code>./output/</code>, you can use:</p>



<p><code>mogrify -monitor -crop 5760x"$((2880-700))"+0+0 -path ./output ./input/*</code></p>



<h2 class="wp-block-heading" id="aioseo-removing-helmet-artifacts-by-adding-a-mask">Removing helmet artifacts by adding a mask</h2>



<p>Adding custom drawn masks, either covering just the helmet or also the surrounding black &#8220;void&#8221; either:</p>



<ul class="wp-block-list"><li>removed the helments but caused extra &#8220;holes&#8221;/missing segments in the ground</li><li>didn&#8217;t remove the helmets</li></ul>



<p>I think this may be due to clashing behaviour of the <code>bg-removal</code> and <code>sky-removal</code> flags with manual masks.</p>



<p>ODM requires a mask image for every image with <code>_mask.{EXT}</code> as a suffix (where <code>EXT</code> replaces the original extension).</p>



<p>The two mask types I tried:</p>



<figure class="wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-3 is-layout-flex wp-block-gallery-is-layout-flex">
<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="2560" height="2474" data-id="360" src="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-scaled.jpg" alt="" class="wp-image-360" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-scaled.jpg 2560w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-300x290.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-1024x990.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-768x742.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-1536x1485.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010284_mask-2048x1979.jpg 2048w" sizes="auto, (max-width: 2560px) 100vw, 2560px" /></figure>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="2560" height="2474" data-id="361" src="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-scaled.jpg" alt="" class="wp-image-361" srcset="https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-scaled.jpg 2560w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-300x290.jpg 300w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-1024x990.jpg 1024w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-768x742.jpg 768w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-1536x1485.jpg 1536w, https://jakecoppinger.com/wp-content/uploads/2022/12/GB010277_mask-2048x1979.jpg 2048w" sizes="auto, (max-width: 2560px) 100vw, 2560px" /></figure>
</figure>



<p>If you know what may be happening please let me know!</p>



<h1 class="wp-block-heading" id="aioseo-further-research-to-be-done">Further research/experimentation</h1>



<ul class="wp-block-list"><li>How many &#8220;capture lines&#8221; per street are necessary to make a decent model? I didn&#8217;t have any luck with one but it may have been my settings. I used ~4 for the above model.</li><li>How much better are models when the camera is on a stick?</li><li>Improved WebODM settings for generation</li></ul>



<h1 class="wp-block-heading" id="aioseo-prior-art">Prior art</h1>



<ul class="wp-block-list"><li>&#8220;A Satellite in Your Pocket: Ground Based Action Cameras to Create Aerial Perspective for OSM Editing&#8221;. This was recorded at OpenStreetMap US: Connect 2020 by Sean Gorman. The company Pixel8 doesn&#8217;t appear to exist any more.<br><a href="https://www.youtube.com/watch?v=tfab-iuWlsQ" target="_blank" rel="noopener" title="">https://www.youtube.com/watch?v=tfab-iuWlsQ</a></li><li>Twitter thread by <a href="https://twitter.com/klaskarlsson">@klaskarlsson</a> (@klaskarlsson@fosstodon.org on Mastodon) on creating a model of his house using a &#8220;GoPro on a stick&#8221;: https://twitter.com/klaskarlsson/status/1583401741386936320</li><li>&#8220;<a href="https://community.opendronemap.org/t/create-aerial-imagery-base-on-360-pictures/12339">Create aerial imagery base on 360° pictures</a>&#8221; &#8211; discussion in the OpenDroneMap community: <a href="https://community.opendronemap.org/t/create-aerial-imagery-base-on-360-pictures/12339" target="_blank" rel="noopener" title="">https://community.opendronemap.org/t/create-aerial-imagery-base-on-360-pictures/12339</a></li></ul>



<p></p><p>The post <a href="https://jakecoppinger.com/2022/12/creating-aerial-imagery-with-a-bike-helmet-camera-and-opendronemap/">Creating aerial imagery with a bike helmet camera (GoPro) and OpenDroneMap</a> first appeared on <a href="https://jakecoppinger.com">Jake Coppinger</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://jakecoppinger.com/2022/12/creating-aerial-imagery-with-a-bike-helmet-camera-and-opendronemap/feed/</wfw:commentRss>
			<slash:comments>17</slash:comments>
		
		<enclosure url="https://jakecoppinger.com/wp-content/uploads/2022/12/measuring-cyclepath-v2.mp4" length="3108898" type="video/mp4" />

			</item>
	</channel>
</rss>
