[daip] AIPS question

Bill Cotton bcotton at nrao.edu
Wed Jul 15 19:58:11 EDT 2009


Eric,

   I see now.  If I do the equivalent of setting CATBLK(KIITY)=2, AIPS
should be happy.  What's its secret FITS HISTORY card name?  I should
fix that as well.  Have to do more when I get around to 2D imaging.

-Bill

Eric Greisen writes:
 > Bill Cotton wrote:
 > > Eric,
 > > 
 > >    One of my users was having a problem using the combination
 > > Imager+CALIB+CLCAL (Imager in Obit, CALIB,CLCAL) in AIPS.  When he did
 > > this on a calibrator and reimaged it, it moved one pixel to the right.
 > > I've confirmed this behavior and that Imager+Calib+CLCal (all in Obit)
 > > does the right thing.  Also, the position in the CC table for the
 > > calibrator was (0,0) and the reference position in the header correct.
 > > I claim this should always give the desired results.
 > >    I suspected that the difference in which pixel is the reference was
 > > causing trouble, (nx/2,ny/2+1) in AIPS, (nx/2+1,ny/2+1) in Obit.
 > > I've traced the problem to the following segment in GRDAT.FOR:
 > > C                                       Get reference pixel offsets from
 > > C                                       tangent point
 > >       IF ((KLNBLK(KIITY).EQ.1) .OR. (KLNBLK(KIITY).EQ.2)) THEN
 > >          XPOFF(JFIELD) = CLNR(KRXPO)
 > >          YPOFF(JFIELD) = CLNR(KRYPO)
 > >       ELSE
 > >          XPOFF(JFIELD) = (CLNR(KRCRP+IRAOFF) - KLNBLK(KINAX+IRAOFF)/2)
 > >      *      * CLNR(KRCIC+IRAOFF)
 > >          YPOFF(JFIELD) = (CLNR(KRCRP+IDECOF) - KLNBLK(KINAX+IDECOF)/2 -
 > >      *      1) * CLNR(KRCIC+IDECOF)
 > >          END IF
 > > What, exactly, is this doing?
 > 
 > My memory is a bit hazy - but one needs the phase shift parameters in 
 > order to subtract the components from the correct location.  All images 
 > made bu AIPS will have KIITY set to 1 (do3d false) or 2 (do3d true) so 
 > that the shift - XPOFF and YPOFF used all over the code that you 
 > initially wrote - will be correctly known.  It is "hidden" in an aips 
 > history card which FITTP writes and IMLOD reads.  The "center" of the 
 > image comes in to some of the handling of the CC files for reasons I 
 > could probably figure out if I took it to be important enough to spend a 
 > couple of days.  The image creation routines set up
 > 
 >        IF (DO3DIM) THEN
 >           CATBLK(KIITY) = 2
 >           CATR(KRXPO) = 0.0
 >           CATR(KRYPO) = 0.0
 >        ELSE
 >           CATBLK(KIITY) = 1
 >           IF (IFIELD.LT.1) THEN
 >              CATR(KRXPO) = 0.0
 >              CATR(KRXPO) = 0.0
 >           ELSE
 >              CATR(KRXPO) = (CATR(KRCRP) - ICNTRX(IFIELD)) * CATR(KRCIC)
 >              CATR(KRYPO) = (CATR(KRCRP+1) - ICNTRY(IFIELD)) *
 >       *         CATR(KRCIC+1)
 >              END IF
 >           END IF
 > 
 > I can see where confusion will come when the Clean image has an odd (in 
 > AIPS) ref pixel but no shift and no evidence in the header to cover this 
 > information.
 > 
 > Looks like another place where the difficulty of popping back and forth 
 > between packages is further revealed.  XPOFF is all over QCLEAN from the 
 > early 1990's.  I think I hit trouble trying to use subimages for models 
 > and that may be when I started to record these data for recovery later.
 > 
 > Eric




More information about the Daip mailing list