[daip] A bug in IMSTAT?
Eric Greisen
egreisen at nrao.edu
Wed Oct 14 18:01:21 EDT 2009
Enno Middelberg wrote:
> Hello,
>
>
> I include below the complete output of IMSTAT and IMEAN. If I understand the
> IMEAN output correctly, the rms of 6.2875E-05 comes from the fit to the
> histogram (and this value is remarkably close to the IMSTAT output of
> 6.3025E-05, which you say is a "simple" rms), and the rms of 5.7077E-05 comes
> from including all data, as it says. And this value is equal to the rms I
> determine with my Python script.
>
> So if the IMEAN rms of 6.2875E-05 comes from a fit to the histogram, what is the
> output of IMSTAT?
>
>
> Regards,
>
> Enno
>
>
>> tget imean
>> default
>> indisk 3; getn 390; go
> AIPS 2: Got(1) disk= 3 user= 6 type=MA S548_lowres.ICL001.1
> IMEAN2: Task IMEAN (release of 31DEC09) begins
> IMEAN2: Initial guess for PIXSTD taken from ACTNOISE inheader
> AIPS 2: Waiting for returned adverbs
> IMEAN2: Image= S548_lowres .ICL001. 1 3 xywind= 1 1 8192 8192
> IMEAN2: Mean and rms found by fitting peak in histogram:
> IMEAN2: Mean=-7.4585E-08 Rms= 6.2875E-05 **** from histogram
> IMEAN2: Mean and rms found by including all data:
> IMEAN2: Mean=-7.7760E-08 Rms= 5.7077E-05 JY/BEAM over 67108864 pixels
> IMEAN2: Flux density = -1.2940E-02 Jy. beam area = 403.28 pixels
> IMEAN2: Minimum=-3.5699E-04 at 2749 8152 1 1
> IMEAN2: Skypos: RA 03 33 35.4629620 DEC -27 45 41.069990
> IMEAN2: Maximum= 3.2447E-04 at 28 2330 1 1
> IMEAN2: Skypos: RA 03 33 35.8729724 DEC -27 45 52.713916
> IMEAN2: Skypos: IPOL 1382.490 MHZ
> IMEAN2: returns adverbs to AIPS
> IMEAN2: Appears to have ended successfully
> IMEAN2: redgum 31DEC09 TST: Cpu= 3.5 Real= 3 IO= 256
> AIPS 2: Resumes
>> imstat
> AIPS 2: Mean=-7.7760E-08 rms= 6.3025E-05 JY/BEAM over67108864. pixels
> AIPS 2: Maximum= 3.2447E-04 at 28 2330 1 1 1 1 1
> AIPS 2: Skypos: RA 03 33 35.8729724 DEC -27 45 52.713916
> AIPS 2: Skypos: IPOL 1382.490 MHZ
> AIPS 2: Minimum=-3.5699E-04 at 2749 8152 1 1 1 1 1
> AIPS 2: Skypos: RA 03 33 35.4629620 DEC -27 45 41.069990
> AIPS 2: Skypos: IPOL 1382.490 MHZ
> AIPS 2: Flux density = -1.2940E-02 Jy. Beam area = 403.28 pixels
These are odd results - I cannot make IMSTAT and IMEAN disagree on very
large images on the simple mean/rms. Furthermore, it is very odd that
your fit rms is larger than the simple one. That is I would think
mathematically impossible - or nearly so. I suppose that the fit can
get wrong answers if the input PIXAVG and PIXSTD are rather wrong but I
would not think that you would be in that state. Did you compile AIPS
locally? There are a couple of things that a bad compiler could mess
up. I will try to fix those to be unambiguous. IMSTAT is really simple
minded - IMEAN tries hard but perhaps we should be a robust average
instead. Of course with 8K by 8K that requires a lot of dynamic memory.
Eric Greisen
More information about the Daip
mailing list