Since memory is typically what limits the number of images that can be processed without error, has anyone tested image compression to reduce the image file sizes to see if it saves memory or effects the quality of the results? I processed about 200 images after compression, and had good results, but not sure if anyone had performed some more controlled testing already. I am not talking about reducing the image resolution, but utilizing apps like MassImageCompressor or others that reduce my 10meg images to around 1meg while maintaining full resolution. Since the software reduces the number of colors utilized from what i understand, the potential loss of small unique color patterns might impact quality of the stitching. Since I am hoping to upload images while in the field to my WebODM server, compressing the images prior to upload could save me considerable time as well. Any thoughts or suggestions?
I would strongly recommend against doing any radiometric compression. It will ruin feature matching.
Try something like mozjpeg or jpegoptim for lossless Huffman table optimization.
Still, they likely get loaded uncompressed for processing, so it won’t matter. RAM usage will be a function of pixel count and bands.
Thank you, I am looking into both of these options now.
Keep in mind that you’re really only saving disk space this way. It shouldn’t affect RAM usage.
Correct. And memory ceilings for the toolchain are the texturing step. MVS-Texturing is the library for that step and there may be ways to dig into this library and reduce the memory requirements within that tool. Changing the inputs (except to reduce resolution) probably won’t have substantive effects on the memory usage in texturing. But, I haven’t profiled it, and my hunches have been quite wrong before.
Thanks for the info. Looks like I could use the compression utilities to speed up uploads without any negative impact on quality.
Yep, that’s about all it might buy you, but it can be significant.
File Optimizer can run a large number of tools against JPEG to simplify this for you. Be aware that the tool is ad-supported and some options can destroy your data (algorithmic compression, for one), but I used it in a previous role to greatly reduce the size of our raw drone data backups.
Another option is to use GDAL and batch things up. Instead of this example with tifs, you can output JPEGs:
I haven’t actually tried this with OpenDroneMap, but it could save a lot of bandwidth back to the server. If you try it, let us know how it works!