terraref / extractors-hyperspectral

Scripts and code relevant to the SWIR and VNIR cameras.
BSD 3-Clause "New" or "Revised" License
6 stars 6 forks source link

mods to op order in rfl_img to increase performance #11

Closed hmb1 closed 7 years ago

hmb1 commented 7 years ago

HI Charlie, have changed the op order to the rfl_img formula to *rfl_img= (rfl_rfr_fct/(xps_img_wht-xps_img_drk))(xps_img-xps_img_drk);**

Do you a preference for the old op order?

This reduces t to two the number of expensive casts from (wavelength-> wavelength,x,y) And so reduces by nearly a third the script runtime

...Henry

czender commented 7 years ago

Looks great to me! Free lunch.