X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 10 Aug 2011 01:28 PM by  anon
difference in values from ENVI script vs. 'band math'
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
10 Aug 2011 01:28 PM
    Hi folks - I am working on automating several raster processing steps that my company does, by writing ENVI / IDL scripts vs. the more tedious act of going through the ENVI gui interface, when needing to run many images. I am performing simple arithmetic operations on Landsat scenes, and using 'math_doit' in the script to perform the math. It is my understanding when one uses the GUI interface and uses 'band math', this also calls the math_doit function, isn't that right? However, when I test my scripts' results against results generated by calling band math in the ENVI gui, the results are different by a small, but not insignificant, fraction (on the order of 2-3%). There appears to be a small offset. I am able to compare my input math_doit expression string to that from band math, and they are the same to 6 significant figures, yet I see differences in the math output well before that degree of accuracy. (ie, my inputs to math_doit agree to .00000x precision, yet output results differ in the .0x decimal place). Any ideas what might be happening, here? Thank you.

    Deleted User



    New Member


    Posts:
    New Member


    --
    13 Aug 2011 01:43 PM
    You should get exactly the same answer - I do all the time. You might want to post a code snippet b/c it's likely one of the more subtle gotchas coming into play. But, you might also want to just forget about 'math_doit' altogether and just use regular IDL commands/functions - a lot of times that's actually the easier way to go! Jeff
    You are not authorized to post a reply.