Forum

Author Topic: Large resolution in orthomosaic model screws up intensities of large pixels  (Read 4139 times)

jmsuomal

  • Newbie
  • *
  • Posts: 17
    • View Profile
We have taken UAV based images of an agricultural field. We are trying to use these images for some advanced processing for which  we need to georectify each picture separately. To smooth out variations within vegetation canopy  in georectification step we resample the images from the 7cm ground sampling distance(GSD) to 5m georeferenced pixels.

We the workflow now working but we noticed a strange effect happening to pixel intensities. Please see the attached image. 

(1.) On top row, you can see the original 7cm GSD image and its histogram. On meter-scale the field is pretty homogenous, but with the small pixels we get a large variation in the intensities. In histogram you can see that we have (reflectance factor) values approximately between 0.2 and 0.55.

(2.) On second row, you can see what should happen to histogram when pixel size get larger. Outside of Photoscan, we applied to the original image a 5m spatial smoothing and this causes the histogram to narrow down only 0.34-0.42 range while the average intensity remains the same. This what expect to see with 5m pixels.

(3.) On third row,  you can see what Photoscan outputs when we used 5m resolution to both build the orthomosaic and 5m resolution to export the orthomosaic. The histogram did not narrow down! Also we received a lot of unexplained noise (and possibly stripes/"oscillations") in the image. The large 5m pixels that should have smoothed out to show values about 0.4 were now showing randomly values approximately within the histogram range of the original 7cm image. Because of such crazy noise, we lost all remote sensing signals we have in the data.

(4.) Last row shows how we got around this. In Photoscan we generated the orthomosaic model at the original 7cm resolution and then used the 5m resolution only in the output of the orthomosaic. With this workflow things seem to work fine and the histogram matches the expected one sufficiently.

So, we got around this problem, but it shows that there is something strange happening in the "build orthomosaic" step. If this not a bug but a feature, then it seems to me that no-one should ever use resolution higher than the GSD in the building of orthomosaics. Thus it would be a good idea to remove that option or at least attach big warning labels to it. 

For this workflow we used python scripting with the following key commands
Code: [Select]
Resolution = 5
doc.chunk.buildOrthomosaic(blending=PhotoScan.BlendingMode.DisabledBlending, color_correction=False, dx=Resolution, dy=Resolution)
doc.chunk.exportOrthophotos(FileName, projection=CoordinateSystem, tiff_compression="none", dx=Resolution, dy=Resolution)

Also such strange effect raises some worries on how well does Photoscan respect the intensities we have in the images. Now we saw this to happen on the 5m pixels, but is there a similar corruption of data happening also on smaller pixel sizes. Can we trust the values of individual georectified pixels if we do the whole process on 7cm resolution? Basically what we need to have is that if we put in images with calibrated reflectance factor values, then we also need to get out the same values without them becoming randomly mutated. Or course there are reflectance anisotropy effects and some sort of fusion of those multiple observations must happen. Thus the input and output can never match perfectly, but for our use this process must be predictable and not add such random changes!