imageprocessing icon indicating copy to clipboard operation
imageprocessing copied to clipboard

Create command-line utility to mimic the Batch Processing notebook

Open poynting opened this issue 6 years ago • 9 comments

Notebooks are nice, but a command-line tool for stacking would be handy

Should, at minimum, take -folder of input images to stack -folder to store the results -explicit path of image to use for alignment -explicit path of image containing a panel -whether or not to generate preview images (e.g. RGB, CIR, etc) -(options) which bands to use for the previews (e.g. 3,2,1 for RedEdge RGB)

Potential additions/improvements:

  • Substitute alignment image with a file specifying the warp matrices
  • Substitute panel image with a file containing a time series of irradiance information
  • Option to stack in parallel using n cores
  • Include reading of a vector polygon file to define area of images to process
  • HTML output report containing map of images like the current notebook

poynting avatar Nov 09 '19 01:11 poynting

@poynting I dig in the subject and find this tutorial that can help. https://towardsdatascience.com/how-to-write-python-command-line-interfaces-like-a-pro-f782450caf0d

jonnyforestGIS avatar Feb 19 '20 11:02 jonnyforestGIS

Hi, I did a rough version of this to process a batch of Altum images. Would be happy to share the code if you think it would be help, although my coding skills are not spectacular. :)

mdanilevicz avatar May 14 '20 04:05 mdanilevicz

Hi, I did a rough version of this to process a batch of Altum images. Would be happy to share the code if you think it would be help, although my coding skills are not spectacular. :)

I'm working on writing something similar at the moment. It'd be amazingly helpful if you could share your code - if you don't mind :)

JPI93 avatar May 24 '20 23:05 JPI93

I would also be interested in this, if possible! I am working with Altum imagery too and it would be very helpful as I'm not a coding professional either. Cheers :)

fischer5 avatar May 25 '20 18:05 fischer5

I'm happy to check out a PR or gist if anyone has code they would like to share.

poynting avatar May 26 '20 05:05 poynting

Sure, no problems. I will take a look at it to check if it is still running and share :)

mdanilevicz avatar May 26 '20 13:05 mdanilevicz

The script is uploaded here https://github.com/moDanilevicz/multispectral_img

To run a test you have to use a few flags: radio_calib_draft.py -i -p -o -t <thumbnails? True/False> --dls <use it?True/False>

The code itself can be improved (and organized) a lot, but hope this can help :)

Edit: Suggestions to improve are more than welcome.

mdanilevicz avatar May 27 '20 04:05 mdanilevicz

@moDanilevicz thanks for linking your code :)

JPI93 avatar May 27 '20 14:05 JPI93

Thanks for working on this all. I have merged @JPI93's code from https://github.com/micasense/imageprocessing/pull/114 into a branch (reconcile-cli-113) and we'll plan to work from there.

poynting avatar Apr 19 '21 05:04 poynting