Problem with Partial Use of Photos during Creation of Orthophoto in WebODM

I have a set of 42 photos with regular spacing and overlap greater than 60%. The area surveyed includes forested landscape. WebODM successfully creates an orthophoto using default settings, but excludes 18 images from the entire set. The task output includes a notice, “Some images can not be added.” Why the reconstruction did not include these 18 images?

A partial listing of the task output shows that only 24 images were used:
[DEBUG] running PYTHONPATH=/code/SuperBuild/install/lib/python2.7/dist-packages /code/SuperBuild/src/opensfm/bin/opensfm create_tracks /var/www/data/e2e5de26-aba2-4335-869b-b16b075f92c2/opensfm
2018-01-26 16:53:31,242 reading features
2018-01-26 16:53:32,152 Merging features onto tracks
2018-01-26 16:53:32,235 Good tracks: 7536
[DEBUG] running PYTHONPATH=/code/SuperBuild/install/lib/python2.7/dist-packages /code/SuperBuild/src/opensfm/bin/opensfm reconstruct /var/www/data/e2e5de26-aba2-4335-869b-b16b075f92c2/opensfm
2018-01-26 16:53:32,719 Starting incremental reconstruction
2018-01-26 16:53:33,409 Starting reconstruction with DJI_0041.JPG and DJI_0042.JPG
2018-01-26 16:53:33,409 Common tracks: 138
2018-01-26 16:53:33,481 Two-view reconstruction inliers 137
2018-01-26 16:53:33,494 Triangulated: 137
2018-01-26 16:53:33,626 Ceres Solver Report: Iterations: 40, Initial cost: 1.197167e+03, Final cost: 1.188262e+03, Termination: CONVERGENCE
2018-01-26 16:53:33,626 Bundle setup/run/teardown 0.000504016876221/0.0357420444489/0.00053596496582
2018-01-26 16:53:33,628 -------------------------------------------------------
2018-01-26 16:53:33,635 DJI_0043.JPG resection inliers: 33 / 33
2018-01-26 16:53:33,636 Adding DJI_0043.JPG to the reconstruction
2018-01-26 16:53:33,671 Ceres Solver Report: Iterations: 2, Initial cost: 1.829957e+03, Final cost: 1.800620e+03, Termination: CONVERGENCE
2018-01-26 16:53:33,672 Bundle setup/run/teardown 0.00154399871826/0.010066986084/0.000962972640991
2018-01-26 16:53:33,672 Removed outliers: 0
2018-01-26 16:53:33,693

.
.
. <cut similar output for added files
.

2018-01-26 16:53:44,390 DJI_0010.JPG resection inliers: 20 / 23
2018-01-26 16:53:44,391 Adding DJI_0010.JPG to the reconstruction
2018-01-26 16:53:45,085 Ceres Solver Report: Iterations: 15, Initial cost: 4.052547e+01, Final cost: 3.872314e+01, Termination: CONVERGENCE
2018-01-26 16:53:45,099 Bundle setup/run/teardown 0.029678106308/0.659130811691/0.0144901275635
2018-01-26 16:53:45,103 Removed outliers: 0
2018-01-26 16:53:45,134 -------------------------------------------------------
2018-01-26 16:53:45,135 Some images can not be added
2018-01-26 16:53:45,135 -------------------------------------------------------
2018-01-26 16:53:45,273 Ceres Solver Report: Iterations: 0, Initial cost: 3.872313e+01, Final cost: 3.872313e+01, Termination: CONVERGENCE
2018-01-26 16:53:45,286 Bundle setup/run/teardown 0.0329360961914/0.104862928391/0.0132720470428
2018-01-26 16:53:45,624 Reconstruction 0: 24 images, 6988 points
2018-01-26 16:53:45,625 1 partial reconstructions in total.

The 2D map output is

I have tried various options, but in all cases these same 18 files are omitted from the reconstruction. This problem seems only to occur in WebODM. I uploaded the same files to a trial version of Precision Mapper and obtained the following orthomap:

The resulting Precision mapper orthophoto map is more complete, but it still seems to have problems in the forested areas.

The complete task output is here, and a zip file of the input images is here

Hey @josephkoonce :hand: try increasing the min-num-features parameter to something like 12000 or 14000. The images were not added because the program couldn’t detect enough good features in those images.

That seems counter intuitive. If the program cannot find 8000 points, why would you specify that it needs even more points to be included? How can it find 12000 when it couldn’t find 8000?

The program always finds 8000 features, just not always good ones. You can find a large number of features in an image (in fact every pixel could be considered a feature, just not necessarily good ones). Matching features between two or more images need to be found in order for an image to be included in the reconstruction. Sometimes images with few good features don’t find matching pairs of images. Increasing the minimum number of features increases the time it takes to process the dataset, but increases the likelihood that enough matching features will be found (because now we can match more features between images!)

We could write pages about how structure from motion works, but others have already done it, so I refer you to chapter 4 and 7 of http://szeliski.org/Book/.

Thanks for the responses to my question. As suggested, I tried a series of increasing min-num-features (8000, 10000, 12000, 14000, 16000, and 24000). As I increased the value of min-num-features, the number of candidate matches between images increased. However, the same set of 18 images was not included in the reconstruction, independent of the value of min-num-features. Trying to reconstruct the map with a subset of images mostly including these 18 images resulted in a “Process exited with code 1” message. It seems to me that finding features in a forest (even with leaf-off view) is difficult. Nevertheless, WebODM seems to have additional difficulty in bridging the forest area to include a images with clear features in the south western part of the orthomap (compare the Precision Mapper output to the WebODM output in my original post). In examining the order of image entry in the image reconstruction, it appears that the reconstruction process proceeds from the south east corner and moves north and west as matching images meet some minimum criteria. As a result, the area in the south west corner of the overlapping images is not added to the reconstruction. I have no idea why Precision Mapper does include this area.

Given, the difficulties that finding common features in vegetation areas create for all image mosaic algorithms, I realize that producing orthomaps from high resolution images of forested areas may be impossible. Are there any known examples of success?

Although I am not a proficient enough programmer to suggest any changes to the fundamental algorithm used in WebODM, I would like to explore the source code in order to better understand the criteria for adding images to the reconstruction. So far, I haven’t been able to find the source code for OpenDroneMap or WebODM. I would appreciate any suggestions.

Thanks.

Since increasing min-num-features wasn’t sufficient, also try to increase matcher-neighbors to 14. It might help.

Source code is available here:

Thanks for the links to the source code. I did increase matcher-neighbors to 14 and 24. The orthomaps were subtly different (perhaps more resolution), but the 18 images are still not added during reconstruction. It seems that some of the forest images have fewer candidate matches to neighboring images than the images that have non-forest features. Would you indicate which module in the source code contains the reconstruction?

OpenDroneMap uses OpenSfM for the reconstruction. Code is available here: https://github.com/mapillary/OpenSfM/

@josephkoonce What app did you use to plan and fly the grid? For homogeneous subjects like you have there, 75% overlap is a bare minimum and 80% is better. Also, it looks like your shutter speed is only 1/100th of a second. You should consider 1/250th as a minimum to reduce motion blur. If you have access to the property, it would be best to just re-fly the mission.

Thanks for your useful suggestions.

I use Litchi for DJI Drones to fly a grid and the Litchi Mission Hub to create individual mission and mission parameters. I have written a short R script to create the mission grid for desired altitude and image overlap from an exported Litchi mission file that has two points (xmin, ymin) and (xmax, ymax) and mission parameters. For anyone interested the code is here. I was able to fly new missions today following your suggestions. However, I had to use a smaller grid to stay within limits of the number of photos allowed by the Litchi Mission Hub. The smaller grid had more photos from forest and reconstruction of the orthomap failed with the “Process exited with code 1” error message. Changing min-num-features as before did not change the outcome. Part of the problem may have been with the 1/240 shutter speed and the cloudy conditions. The photos are a bit underexposed. Originally, I used a 1 second flight pause before taking a photo to reduce motion blur. I flew a second mission with auto camera settings, but it still failed at the beginning of the reconstruction.

I intend to continue exploration of the options and grid spacing under different light conditions.

Litchi is a great app. Although using it for flying grid missions seems like a lot of work to me. Is there a particular reason why you do not want to use one of the apps designed specifically for this purpose.

Map Pilot is the best I have used. Drone Deploy and Pix4D Capture are free I believe.

If lighting is poor, you can go to iso 200. I wouldn’t go any higher though.

I have a big Problem yet described and discussed in this task.I have drone pictures over forest and it is impossible to get a complete orthofoto. Just a quarter will be finished. What can I do? I tried out all adaptions of Parameters described here, but nothing changes…

Thank you !

@TommyB please open a new topic. This one is several months old!