Public Lab Research note


  • 4

Mapping rugged coastal environments with a Raspberry Pi and a balloon?

by samwf |

The short:

I'm a geoscience graduate student. For my project, I need high-resolution, quantitative topographic data.

I want to collect these data using an inexpensive, DIY solution.

If you can help with:

  1. setting up a Raspberry Pi Zero for time-lapse photography, ideally in a raw image format;
  2. ways to collect these data in rugged coastal environments;
  3. ways to make these data quantitative (i.e. spatially accurate);
  4. processing image files with free photogrammetry software to create high-resolution 3D models;

please get in touch! All help and advice will be much appreciated. If you would like to get more involved with my project, let me know.

Ultimately, I want to create a step-by-step tutorial on Public Lab that will enable others to collect high-resolution, quantitative topographic data suitable for scientific research.


The long:

I'm a graduate student at the GFZ in Germany: http://www.gfz-potsdam.de/en/home/.

My project is all about how the properties of materials in a landscape (e.g. rock, soil, sand) interact with the different processes acting on that landscape (e.g. river incision, landsliding, wave quarrying). My approach involves finding ways to quantitatively compare the shape of a landscape with the substrate properties.

In order to do this, I need high-resolution, quantitative topographic data. My chosen field sites are rocky coastlines, which can be challenging to map.

To collect these data, I'd like to use an inexpensive, DIY solution, and then share my method and data with others. This could be a new method, or a new application of an existing method, or just an existing method.

Here's a list of everything I've bought so far:

  1. Raspberry Pi Zero
  2. 9V AA battery pack
  3. UBEC 5V 3A step-down converter
  4. Raspberry Pi camera module V2
  5. Raspberry Pi Zero camera cable
  6. USB SD card reader
  7. Raspberry Pi power supply

image description

I'll be doing everything with a Mac; my programming language of choice is Python.

The simplicity of pole aerial photography is very appealing, but I don't think it's suitable for my purposes; kite and balloon aerial photography are better suited. However, I don't think photographing a cliff will be easy with a kite. So, at the moment, I think a balloon rig would be the best. In order to get a bit more control over the position of the balloon at lower elevations (and in windy weather), I was thinking of a setup like this:

image description

In order to make the data spatially accurate, I was thinking of using something like this:

image description

This will probably work to improve accuracy in the xy-plane; maybe not so much in the z-direction.

I also need to work out a good way to make a lightweight, adjustable mount for my camera.

As mentioned above, if you can help with:

  1. setting up a Raspberry Pi Zero for time-lapse photography, ideally in a raw image format;
  2. ways to collect these data in rugged coastal environments;
  3. ways to make these data quantitative (i.e. spatially accurate);
  4. processing image files with free photogrammetry software to create high-resolution 3D models;

please get in touch! All help and advice will be much appreciated. If you would like to get more involved with my project, let me know.

Thanks very much in advance!



balloon-mapping photogrammetry raspberry-pi photo-monitoring timelapse coast topography high-resolution

8 Comments

This looks like a great project.
The photos used for structure from motion models should have a few characteristics:

  1. They should be high image quality (so the software can find matching control points in overlapping photos). Good photos also makes your final textured model look awesome.
  2. There should be multiple photos from different angles of each part of the surface.
  3. For quantitative work, each photo should have GPS coordinates of the camera associated with it.

Control points on the ground (GCPs) can replace or augment GPS coordinates of the camera, but placing GCPs along a rocky coastline could be much more difficult than obtaining GPS data. How you scale and georeference the model will depend on the software you use, so figure that out first so you know how important it will be to collect GPS data with each photo.

My first choice for this type of data collection would be a point & shoot camera with integrated GPS. The image quality is much better than a Pi camera. Canon PowerShots with CHDK can shoot at any time interval and be triggered remotely. A used PowerShot S100 with GPS costs $150. The sensor and lens are better than typical PowerShots. The rechargeable battery lasts for as many as 1000 photos. The camera weighs 200 grams.

If the rocky cliffs are steep and craggy, some photos should be taken at an angle instead of downward. For structure from motion, nadir photos might not capture enough detail of vertical or overhanging surfaces. This probably requires a pan/tilt camera mount.

Flying the camera depends on the landscape and geography. If there are trees everywhere, kites probably won't work. If it is a windy coast, balloons probably won't work. If the wind always blows onshore, kites won't work unless you have a boat. If you live next to the study site, you can wait for the perfect weather conditions, but if the site is remote, much luck is involved in being there when the conditions reward the choice you made for lifting the camera. Drones usually work in a wider range of weather, landscape, and vegetation conditions. Local authorities sometimes impose stricter restrictions on drone flying.

The cameras built into sub $1000 drones are not as good as a PowerShot S100, but some are good enough. A drone always has GPS, but not all of them write the GPS data to each photo. Some drones have gimbals which can point the camera, and some drone controllers have displays which show you what will be in each photo. Some drones can be programmed to fly around and take any series of photos you instruct it to.

So if I were starting from scratch, I would buy a drone for this project. Since I am not starting from scratch, I would take my four kites (for different wind conditions) and a Saturn V Rig with S100, and plan to spend lots of time waiting for the right wind.

A Saturn V Rig with S100 is on sale right now at the KAPtery. Maybe luck is on your side, at least for a while.

Chris


Thanks for the awesome feedback, Chris!

Another way to tackle some of the problems presented by my project is to define a meaningful 'contour'. For example, the transition from sedimentary deposits to intact, in-place bedrock along a rocky coast (see image below). This would give a 'contour' without a constant elevation (hence the quotes). Another meaningful contour might be the mean high water line.

IMG_1375.jpg

For planar curves like this, I would only need high resolution in the xy-plane.

To collect this kind of data, I would obviously need access to the area below the cliff. With a pole / balloon / kite, do think I could build an accurate model of my chosen contour through a combination of: 1) ground control points; 2) a GPS-enabled camera; 3) 'overview' shots that capture large parts of the scene; 4) 'detail' shots that capture small-scale details?

IMG_1377.jpg

Thanks again!

Sam.


I think what you are proposing is quite realistic. Depending on the scale of your study areas (e.g., How tall are the cliffs?), this could be accomplished with a good pole. If the landscape feature is bigger, walking a helium balloon around (above and below the cliff) might help. Or if the wind is amenable, walking a kite around. If you can do the whole thing with a pole, pointing the camera is much easier, and it requires less practice, less money, and less waiting for good weather (although photography for sfm is best done on cloudy bright days with minimal shadows).

Getting photos both near and far from the surface is probably a good idea. How much this helps might depend on the software you are using. Placing GCPs on the surface can also help if the software knows what to do with them.

I don't have much experience with sfm software, but it seems that the technology is so powerful that a good program can solve many of your problems. Even without GPS or GCPs, walking around with a good camera and maybe a 7m pole and getting lots of good overlapping photos of all points on the surface from different angles is all that is required. If you capture the right set of photos, the software can produce an incredibly good 3D model textured with the photos. The model can be scaled by measuring a few distances between landmarks in the scene. Or if each photo has GPS data and the proper software is used, the model will be scaled when it is made. Done.

You can then view this 3D model from above to trace the "contour" of interest, and view it from the side to see if the same contour is a contour. With the right software, a scaled model can be analysed for surface area and volume.

Below is a one minute video (no audio) of two 3D models made from kite photos taken by a PowerShot S100. The models were made in ReCap360 which is a free online service (better results are possible with a paid account). The kite photos were not taken with the intention of doing sfm, but were handy examples for illustrating how easy and tolerant the process is. More carefully captured photos would have produced more detailed and accurate models. These models are not scaled but they could have been had I asked the program to scale them. More about these models here.

So it might be that you should immediately take the best camera you can find and maybe a pole of some kind and go to the beach and take a lot of photos on a bright but cloudy day. Then try some sfm programs and maybe by the end of the day you will be well on your way to graduating.

Chris


All the science aside - that is a beautiful photo you have there at the top. A truly mesmerizing view.


Thanks @LucyTaylor!

It's a smartphone panorama. I took it on the morning of my birthday at Winspit Cove (https://en.wikipedia.org/wiki/Winspit). I panned the camera quickly because I was worried the waves would mess up the image, which is why the horizon is a bit bendy.


@cfastie: thanks again for your feedback!

Re: cameras, I have access to a friend's Fujifilm X100s. It has a fixed focal length, and it's easy to program the exposure settings, etc. In fact, it's a really nice camera! However, it doesn't have built-in GPS. I could probably use a phone, or handheld GPS unit instead, but this would give my location rather than the location of the camera. Alternatively I could record the GPS coordinates for my ground control points. Obviously this means that there would be fewer GPS reading as input for the photogrammetry software. What do you think? Should I use a really nice camera without GPS, or try to beg / borrow one that does?

P.S. Collecting these data is just one small step towards graduating...


I think the answers to your latest questions depend a lot on the sfm software you will be using. Some online services don't use GPS data, so it won't help to have it. A good first step might be to learn how to take the kind of photos which produce 3D models with adequate coverage and resolution. Without getting GPS involved, you can create models which will tell you what kinds of things you could learn from them. You will also learn how many photos are needed and therefore how large a study site can be included in a single model (also depends on the software). You could also take photos with a phone to see how the quality compares to a better camera (but first figure out how to export the phone photos so that they have GPS data in the exif headers).

Your decisions will also depend on whether you will need to fly the camera vs holding it on a pole or hand-holding it. Even putting a camera on a pole involves some risk of damage (especially around sand and rocks and saltwater). If you don't need to fly the camera, you could consider investing more in it.

For a serious research project, you will probably eventually settle on either using a good camera with GPS or using high end software (e.g., Agisoft Photoscan). You probably should use both. Combining photos which have GPS data with software that knows what to do with both photo GPS and GCPs will allow the most flexibility. Standalone software like Photoscan requires a big computer if you want to make models with 200 or more photos.

Another variable is how many different sites you will model. If you want to do 30 different sites, having GPS in the camera could eliminate the need to place and locate GCPs -- just show up at a site and start taking photos. Without GCPs, there will be (a little bit?) more uncertainty about the dimensions in the models, but depending on the type of analysis you are doing that might not make any difference in your results.

Below is an example of an extensive 3D model made from kite photos. Just so you know what is possible.

Chris

Jarlshof from Kieran Baxter on Vimeo.

BTW, Lucy is likely a spam account who just wanted to post a link in his profile to game search. Don't agree to meet her for coffee.


@cfastie: The spam accounts are multiplying!

Thanks again. I'll be collecting data in the field over the next few weeks. I'll let you know how I get on.

Sam.


You must be logged in to comment.