Re: Envi band math help! [message #35720] |
Sat, 12 July 2003 18:03  |
tianyf_cn
Messages: 19 Registered: November 2002
|
Junior Member |
|
|
If your array is not very large, I sugguest that you use IDL procedure
to print the single pilex value of b1. It a good choice to perform
math operations on each pixel of b1 by ENVI Band Math Tool.
I tested the second example, and found that ENVI first do some tests
on the specified expression. It generates a random 5*5 array to test
the math expression and then use ENVI TILE to cycle the calculation.
When you type the expression in band math tool:
example(b1)
and click the OK button, it first executes the example.pro by using
the random array(5*5).
You can set a breakpoint in you math funcion to see how it works.
Tian.
gauravjn123@yahoo.co.in (Gaurav) wrote in message news:<d193b5fb.0307110209.5ab0ce0c@posting.google.com>...
> Hi!
> I have this strange problem...i have written one band math function
> to print the band value at the location 30,30 but it doesnt work. And
> the same function if written for location 4,4 ...works fine! Here are
> the functions:
>
> 1.function example,b1
> help,b1
> print,b1(30,30)
> end
> 2.function example,b1
> help,b1
> print,b1(4,4)
> end
> And strangely enuf...in the second example, the value b1(4,4)
> is printed 4 times & the value printed final time is the right
> value. The help command outputs that the array is of size[5,5] in the
> initial 3 times. Only after that in the final turn does it output the
> right dimesnions that is 608*673
>
> Could anyone please enlighten me....it has been bugging me for many
> days!
> Thnx in advance
>
> Gaurav
|
|
|
Re: Envi band math help! [message #35810 is a reply to message #35720] |
Mon, 14 July 2003 13:12  |
gauravjn123
Messages: 7 Registered: July 2003
|
Junior Member |
|
|
Hi!
Well even i had felt the same...And therefore i also tried to use a
procedure to output those pixel values...but unfortunately i was not
able to use the envi widgets to input the five bands in an image...so
i reverted back to band math functions for it.
If it is not possible to output a single pixel value using
functions, could you please tell me how to input the band values using
a procedure (Could you please give me a sample procedure to input 5
bands in an image)
Thanking you in advance.
Gaurav Jain
ENST-Bretagne
tianyf_cn@yahoo.com.cn (TIAN Yunfeng) wrote in message news:<42e9d2cb.0307121703.8a0229c@posting.google.com>...
> If your array is not very large, I sugguest that you use IDL procedure
> to print the single pilex value of b1. It a good choice to perform
> math operations on each pixel of b1 by ENVI Band Math Tool.
>
> I tested the second example, and found that ENVI first do some tests
> on the specified expression. It generates a random 5*5 array to test
> the math expression and then use ENVI TILE to cycle the calculation.
> When you type the expression in band math tool:
> example(b1)
> and click the OK button, it first executes the example.pro by using
> the random array(5*5).
>
> You can set a breakpoint in you math funcion to see how it works.
>
> Tian.
>
> gauravjn123@yahoo.co.in (Gaurav) wrote in message news:<d193b5fb.0307110209.5ab0ce0c@posting.google.com>...
>> Hi!
>> I have this strange problem...i have written one band math function
>> to print the band value at the location 30,30 but it doesnt work. And
>> the same function if written for location 4,4 ...works fine! Here are
>> the functions:
>>
>> 1.function example,b1
>> help,b1
>> print,b1(30,30)
>> end
>> 2.function example,b1
>> help,b1
>> print,b1(4,4)
>> end
>> And strangely enuf...in the second example, the value b1(4,4)
>> is printed 4 times & the value printed final time is the right
>> value. The help command outputs that the array is of size[5,5] in the
>> initial 3 times. Only after that in the final turn does it output the
>> right dimesnions that is 608*673
>>
>> Could anyone please enlighten me....it has been bugging me for many
>> days!
>> Thnx in advance
>>
>> Gaurav
|
|
|