IRAF V2.12EXPORT RELEASE NOTES

Last Modified: Wed May 8 21:05:09 MST 2002

These release notes provide a summary of the major changes in V2.12. This is a major release of IRAF and will be available for all supported platforms. More detailed technical documentation of all system changes will be found in the 'notes.v211' and 'notes.v212' files in the iraf$doc and iraf$local directories. Detailed revisions notes for each application package are in the package directories in a file called Revisions, e.g. apphot$Revisions.


Table of Contents:





1. Highlights of This Release




2. IRAF System Revisions Summary




3. Core IRAF Revisions Summary
3.1 New Tasks
     imcoords.ccget - extract objects from a test file catalog
     imcoords.ccstd - transform to and from standard astrometric coordinates

proto.mimstatistics - do image statistics through a mask
      proto.rskysub - sky subtract images using running mean or median
      proto.mskexpr - general mask expression evaluator
   proto.mskregions - create a mask from a list of region specifications
3.2 Existing Tasks with New Parameters or New Parameter Defaults
 immatch.imcentroid - new parameter maxshift
    immatch.imalign - new parameter maxshift
     immatch.geomap - new parameter maxiter, default reject = 3.0 not INDEF

     imcoords.ccmap - new parameter maxiter, default reject = 3.0 not INDEF
  imcoords.imcctran - new parameter longpole

       imutil.hedit - new parameter addonly
imutil.imstatistics - new parameters nclip, lsigma, usigma, cache
3.3 Existing Tasks with New Capabilities
 immatch.imcentroid - optionally rejects objects whose centers wander too much
    immatch.imalign - optionally rejects objects whose centers wander too much
     immatch.geomap - iterative rejection capability added

     imcoords.ccmap - iterative rejection capability added 
  imcoords.imcctran - support for non-zenithal projections added

       imutil.hedit - support for add keyword only if new option
imutil.imstatistics - support for iterative rejection and memory caching added
      imutil.imexpr - support for bitwise operators or, and, xor, and not added




4. NOAO Package Revisions Summary
4.1 New NOAO Packages

      astcat - Astronomical catalog and surveys access package
      crutil - Cosmic ray detection and removal package
     obsutil - Observing utilities package
4.2 New NOAO Package Tasks

      apphot.pcalc - Do arithmetic operations on a list of apphot databases
   apphot.pconvert - Convert a text database to a tables database

      apphot.pdump - Print selected fields from a list of apphot databases
   apphot.pexamine - Interactively examine and edit an apphot database
  apphot.prenumber - Renumber stars in an apphot database
    apphot.pselect - Select records from an apphot database
      apphot.psort - Sort an apphot database

     astcat.aclist - List the supported astrometric catalogs
    astcat.agetcat - Extract astrometry files from astrometric catalogs
   astcat.afiltcat - Filter astrometry files derived from astrometric catalogs 
   astcat.adumpcat - Catalog access debugging task

     astcat.aslist - List the supported image surveys 
     astcat.agetim - Extract FITS images from image surveys 
     astcat.ahedit - Initialize the image wcs and set standard keywords

    astcat.aimfind - Select images containing catalog objects
    astcat.adumpim - Image survey access debugging task
   astcat.aregpars - Default region parameter set
   astcat.acatpars - Default astrometry file format parameter set 
  astcat.afiltpars - Default astrometry file filtering parameters
    astcat.aimpars - Default image data parameters
   astcat.awcspars - Default image wcs parameters

 crutil.cosmicrays - Remove cosmic rays using flux ratio algorithm
  crutil.craverage - Detect CRs against average and avoid objects
  crutil.crcombine - Combine multiple exposures to eliminate cosmic rays

     crutil.credit - Interactively edit cosmic rays using an image display
      crutil.crfix - Fix cosmic rays in images using cosmic ray masks
     crutil.crgrow - Grow cosmic rays in cosmic ray masks

   crutil.crmedian - Detect and replace cosmic rays with median filter
   crutil.crnebula - Detect and replace cosmic rays in nebular data

obsutil.psfmeasure - Measure PSF sizes from stellar images
 obsutil.specfocus - Determine spectral focus and alignment variations
 obsutil.starfocus - Determine direct focus variations from stellar images
   obsutil.ccdtime - CCD photometry exposure time calculator
  obsutil.pairmass - Plot airmass vs time for a given coordinate
    obsutil.sptime - Spectroscopic exposure time calculator
  obsutil.specpars - Spectrograph instrument parameters for sptime
  obsutil.bitcount - Accumulate the bit statistics for a list of images
  obsutil.findgain - Estimate the gain and readnoise of a CCD 
   obsutil.shutcor - Shutter correction from images of varying exposure times

   nproto.objmasks - detect and catalog objects in image
4.3 Existing Packages and Tasks with New Parameters or New Parameter Defaults

            apphot - new package parameters wcsin, wcsout, and cache
     apphot.center - new parameters wcsin, wcsout, cache
    apphot.daofind - new parameters wcsout, cache
     apphot.fitpsf - new parameters wcsin, wcsout, cache
     apphot.fitsky - new parameters wcsin, wcsout, cache
       apphot.phot - new parameters wcsin, wcsout, cache
   apphot.polymark - new parameters wcsin, wcsout, cache
   apphot.polyphot - new parameters wcsin, wcsout, cache
      apphot.qphot - new parameters wcsin, wcsout, cache
    apphot.radprof - new parameters wcsin, wcsout, cache
      apphot.wphot - new parameters wcsin, wcsout, cache
     apphot.txdump - replaced by pdump, available as a hidden task

astutil.setairmass - new parameters ra, dec, equinox, st, ut, scale

           daophot - new package parameters wcsin, wcsout, wcspsf, and cache
   daophot.addstar - new parameters wcsin, wcsout, wcspsf, and cache
   daophot.allstar - new parameters wcsin, wcsout, and wcspsf
   daophot.daoedit - new parameters cache
   daophot.daofind - new parameters wcsout, and cache

     daophot.group - new parameters wcsin, wcsout, wcspsf, and cache
     daophot.nstar - new parameters wcsin, wcsout, wcspsf, and cache
      daophot.peak - new parameters wcsin, wcsout, wcspsf, and cache
      daophot.phot - new parameters wcsin, wcsout, and cache
       daophot.psf - new parameters wcsin, wcsout, and cache
   daophot.substar - new parameters wcsin, wcsout, and cache
4.4 Existing Tasks with New Capabilities

     apphot.center - coordinate system support, optional image cacheing
    apphot.daofind - coordinate system support, optional image cacheing
     apphot.fitpsf - coordinate system support, optional image cacheing
     apphot.fitsky - coordinate system support, optional image cacheing
       apphot.phot - coordinate system support, optional image cacheing
   apphot.polymark - coordinate system support, optional image cacheing
   apphot.polyphot - coordinate system support, optional image cacheing
      apphot.qphot - coordinate system support, optional image cacheing
    apphot.radprof - coordinate system support, optional image cacheing
      apphot.wphot - coordinate system support, optional image cacheing

astutil.setairmass - ra, dec, equinox, st, ut, scale are no longer hardwired
 astutil.rvcorrect - more flexibility in setting ut

   daophot.addstar - coordinate system support, optional image cacheing
   daophot.allstar - coordinate system support
   daophot.daoedit - optional image cacheing
   daophot.daofind - coordinate system support, optional image cacheing
     daophot.group - coordinate system support, optional image cacheing
     daophot.nstar - coordinate system support, optional image cacheing
      daophot.peak - coordinate system support, optional image cacheing
      daophot.phot - coordinate system support, optional image cacheing
       daophot.psf - coordinate system support, optional image cacheing
   daophot.substar - coordinate system support, optional image cacheing




5. General Package Changes

NOAO

ONEDSPEC

APPHOT

ASTCAT

IMRED.CRUTIL

IMRED.QUADRED

DAOPHOT

OBSUTIL


               PSFMEASURE    STARFOCUS   SPECFOCUS    CCDTIME       
               PAIRMASS      SPTIME      BITCOUNT     FINDGAIN    
               SHUTCOR

OBSOLETE





6. General Task Changes

NOAO
ONEDSPEC.SPLOT

ASTUTIL.SETAIRMASS

ASTUTIL.RVCORRECT

IMRED.ECHELLE.ECIDENTIFY

IMRED.CCREDRED.COSMISRAYS

NPROTO.FINDGAIN

NPROTO.OBJMASKS

TWODSPEC.LONGSLIT.FITCOORDS

TWODSPEC.APEXTRACT.APEDIT

IMAGES

TV.DISPLAY

TV.IMEXAMINE

IMMATCH.IMCOMBINE

IMMATCH.IMCENTROID
IMMATCH.IMALIGN

IMMATCH.GEOMAP
IMCOORDS.CCMAP

IMCOORDS.STARFIND

IMCOORDS.IMCCTRAN

IMCOORDS.CCGET

IMCOORDS.CCSTD

IMUTIL.HEDIT

IMUTIL.IMSTATISTICS

IMUTIL.IMEXPR

PROTO.MIMSTATISTICS

PROTO.RSKYSUB

PROTO.MSKEXPR

PROTO.MSKREGIONS

XTOOLS.SKYWCS

XTOOLS.CATQUERY

SYSTEM.HELP

SYSTEM.LROFF





7. Parameter File Changes

In the tables below each parameter change is identified with one of the following codes followed by task name and the description of the change.

CL

  n cl                      Added the new CL parameter "release".  This
                            is a string valued parameter with values such
                            as "2.11.3a", "2.12", "3.0" etc.  This differs
                            from "version" which is a descriptive string
                            such as "NOAO/IRAF V2.11.3 EXPORT".  There can
                            be multiple releases of one version of the
                            software, and "release" specifies exactly what
                            build the software is.  The release strings are
                            composed in such a way that they can be used
                            in expressions, e.g. (release >= 2.11.3) would
                            be true for IRAF V2.11.3 and all subsequent
                            releases.

DATAIO

  c dataio.export           Made the 'format' parameter automatic mode
  c dataio.import           Made the 'format' parameter automatic mode

IMAGES

  n imcoords.imcctran       Added a new parameter longpole to the imcctran
                            task. If longpole=yes then coordinate transfor-
                            mations with zenithal projections will be rot-
                            ated using longpole rather than the CD matrix.

  c immatch.wregister       Fixed boundary option typo, "refect" to "reflect".
  c immatch.sregister       Fixed boundary option typo, "refect" to "reflect".

  n immatch.imcentroid      Added a new parameter maxshift to the imcentroid
    immatch.imalign         and imalign tasks.  Maxshift is the maximum perm-
                            itted difference between the computed and predicted
                            shifts. Maxshift can be used to reject objects whose
                            centers have wandered too far from the expected
                            center. By default maxshift is undefined.

  n immatch.geomap          Added a new parameter maxiter to the geomap and
    immatch.ccmap           ccmap tasks. Maxiter defines the maximum number of
                            rejection iterations and has a default value of 0
                            for no rejection.  

  c immatch.geomap          Changed the default value of the ccmap and geomap
  c immatch.ccmap           parameter reject from INDEF to 3.0.

  c immatch.imcombine       Numerous changes, see details above

  c imgeom.imlintran        Changed the nrows argument names to nlines 
  n imutil.hedit            Added a new addonly parameter to the hedit task. If
                            addonly is set a new field will only be added to
                            the image header if it does not already exist.

  n tv.imexamine            Added new parameters 'output', 'ncoutput', and
                            'nloutput' used by the new 't' keystroke when
                            outputting an image section centered on the cursor.

SYSTEM

  n help                    New parameters required for GUI options, output
                            formats for HTML/PS, printer, etc.
  n lroff                   Added new 'format' parameter for HTML/PS output 

UTILITIES

  c utilities.surfit        Added support for the half cross-terms option to
                            the surfit task.  This involved changing the type
                            of the xterms parameter from boolen (yes/no) to
                            string (none,half,full).

NOAO

ASTUTIL
n astutil.setairmass new parameters ra, dec, equinox, st, ut, scale

DIGIPHOT

    n apphot                new package parameters wcsin, wcsout, and cache
    n apphot.center         new parameters wcsin, wcsout, cache
    n apphot.daofind        new parameters wcsout, cache
    n apphot.fitpsf         new parameters wcsin, wcsout, cache
    n apphot.fitsky         new parameters wcsin, wcsout, cache
    n apphot.phot           new parameters wcsin, wcsout, cache
    n apphot.polymark       new parameters wcsin, wcsout, cache
    n apphot.polyphot       new parameters wcsin, wcsout, cache
    n apphot.qphot          new parameters wcsin, wcsout, cache
    n apphot.radprof        new parameters wcsin, wcsout, cache
    n apphot.wphot          new parameters wcsin, wcsout, cache

    n daophot               new package params wcsin, wcsout, wcspsf, and cache
    n daophot.addstar       new parameters wcsin, wcsout, wcspsf, and cache
    n daophot.allstar       new parameters wcsin, wcsout, and wcspsf
    n daophot.daoedit       new parameters cache
    n daophot.daofind       new parameters wcsout, and cache
    n daophot.group         new parameters wcsin, wcsout, wcspsf, and cache
    n daophot.nstar         new parameters wcsin, wcsout, wcspsf, and cache
    n daophot.peak          new parameters wcsin, wcsout, wcspsf, and cache
    n daophot.phot          new parameters wcsin, wcsout, and cache
    n daophot.psf           new parameters wcsin, wcsout, and cache
    n daophot.substar       new parameters wcsin, wcsout, and cache

ONEDSPEC

    n standard              new parameter mag, magband, and teff.  These 
    n splot                 params can be use to specify calibration files
    n lcalib                as blackbody curves scale to a specified magnitude

TWODSPEC

    c apextract.apall1      Reduced the 'polysep' parameter.
    c apextract.apdebug     Reduced the 'polysep' parameter.
    c apextract.apfit1      Reduced the 'polysep' parameter.
    c apextract.apnoise1    Reduced the 'polysep' parameter.
    c apextract.apnorm1     Reduced the 'polysep' parameter.
    c apextract.apparams    Reduced the 'polysep' parameter.





8. Details of Major System Changes

8.1 FITS kernel changes

The FITS kernel was modified to add support for storing images in extensions as compressed pixel masks. The mask is stored as a binary table using the "ZIMAGE" (compressed image) convention proposed by White, Greenfield, Pence, and Tody in 1999:

            http://heasarc.gsfc.nasa.gov
            /docs/software/fitsio/compression/compress_image.html

In the current implementation only the "PLIO_1" compression algorithm is implemented. Mask extensions may be read or written directly by the kernel. When writing a new extension it will be appended to the MEF file. To append an image to a MEF file as a mask, include "type=mask" in the image kernel section when the output image is opened.

Masks are interfaced to the system as images and may be read and written like any other image via IMIO. They have a normal image header and can be manipulated with any program that deals with images. The pixel type is INT.

It is also possible to access a mask image as a PLIO mask. An IMSTATI query for IM_PLDES parameter will return the PLIO mask descriptor. While a mask extension is opened under IMIO it is represented as a PLIO mask and may be accessed in this form like any other mask.

The mask image is stored in the FITS binary table (BINTABLE) extension when the image is closed, and is loaded from the extension when the image is opened. The compression representation used to store the mask in the binary table is the same as is used within PLIO. The new (V2.12) encoding is used, allowing very large masks to be stored. Currently masks up to 3D are supported. Data on each 2D mask plane will be compressed in both X and Y as with PLIO. The depth of the mask is preserved.

Although a mask is stored as a binary table the format of the table is not completely general. In the current implementation there can be only one column in the table (COMPRESSED_DATA). This is an integer-valued variable length array column containing, for each line of the N-dimensional image, the PLIO compressed version of that image line. The actual compressed data is stored in the heap area of the table. Multiple image lines may point to the same compressed line list, e.g., to store the empty line or to compression in Y.



8.2 Large Image Support

The following changes were made to enable IMIO to use larger buffer sizes to optimize i/o for large images:

The default file buffer size set by IMIO is unchanged: it is still about 512 MB, the value set for V2.11.2. However, a new parameter IM_BUFFRAC was added. Both IM_BUFSIZE and IM_BUFFRAC are used to help determine the FIO buffer size set when an image is opened. The logic for this is implemented in imsetbuf.x.

Backwards compatibility. If you do nothing about IMIO/FIO buffers in your program, the system may transparently use a larger buffer for larger images. If you set BUFSIZE in your program, the system will by default use the value you give, or possibly a larger value, if the image you are accessing is very large. If you set BUFSIZE and you want to guarantee that the value you set is used (even for very large images) then you should also set BUFFRAC=0 to ensure that only BUFSIZE is used.

How it works. BUFFRAC specifies the default FIO buffer size used to access an image, expressed as a percentage of the size of the image. For example, the builtin default value of BUFFRAC=10 will try to make a FIO buffer 10% of the size of the image. The actual value used will be given by BUFFRAC, but will be at least BUFSIZE, and no more than a builtin default maximum value, currently 32 MB. Given the builtin defaults, the buffer size will range from 0.5 to 32 MB depending upon the size of the image being accessed. As noted above, BUFSIZE and BUFFRAC can be set to force the buffer size to a specific value if desired.

Environment variables for both parameters are provided. The names are "IMIO_BUFSIZE" (specified as bytes) and "IMIO_BUFFRAC" (specified as a decimal fraction). If defined, these override (at image open time) the builtin default values for both parameters. An IMSET call by the application will override all such defaults.

The FIO buffer allocated will not be larger than the size of the image. The FIO buffer will also not exceed the maximum size set by the file driver being accessed. For example, for PLIO images the file buffer will not exceed about 2KB, even for a very large mask. This is because the "pixel file" for a PLIO image is dev$null, the driver for which specifies a maximum i/o buffer size of 2K (the real file to load or save the mask will use a different descriptor).

The intent here is to provide an adaptive mechanism for setting the FIO buffer size used to access an image, which automatically adapts to the size of the image being accessed. If you access a lot of small images you will get smaller buffers - everything will be as before. If you access very large images, you may get large buffers up to the builtin maximum value of (currently) 32 MB.

Using large buffers could cause a machine to run out of memory. However, it is likely that if someone is working on 300 MB images that they are using a machine which has a memory at least that large (probably larger). If there are problems, the environment variable overrides can be used to tune IMIO.

The reason for large file buffers is to limit the number of disk data transfers, and hence the number of disk seeks. Using buffers larger than a certain amount (32 MB is generous) is probably counterproductive. If the i/o system provides 20 MB/sec i/o transfers, 32 MB will take 1.6 seconds. This should be more than a large enough granularity to provide efficient i/o, hence is a reasonable limit (at this point paging effects are likely to dominate).



8.3 Virtual Memory Cache

The VMcache client interface and daemon provide a method by which data-intensive IRAF tasks (or non-IRAF tasks for that matter) can manage how files/images are maintained in virtual memory to avoid excessive system paging. In essence it's a way to "lock" a specific image in memory to improve performance.

Since the VMcache interface is built into the low-level binary file driver, all IRAF tasks which access large files are affected and All it takes is an executing vmcache daemon on the same host computer to be doing Vmcacheing. In other words, the client-side VMcache stuff is all down in the binary file driver (zfiobf). No changes to applications code (IRAF tasks) are required. You can start up a vmcached now on a Solaris system even while an IRAF session is running, and it will start managing the cache. The cache monitors all file accesses and works behind the scenes. The only case where the application might need to know about VMcache are special system-wide applications like the DHS, or a big pipeline with many processes, where explicit control of the cache might be useful.

For high data volume background jobs one can either use Vmcache, set to cause the same region of memory to be reused for file data, or use direct i/o, which is much simpler. For example for a big tape job on the DHS we can now just enable directio in the host environment for the IRAF tape job, and all the i/o will be done without going through system memory, getting up to 30 MB/sec off the striped disk.

The following notes summarize the changes made for this feature and describe it's function in more detail. A more complete description of the interface, environment variables which control it, etc can be found in the main systems revisions file iraf$local/notes.v211.

The source for the developmental version of the VMcache library and the VMcache daemon (vmcached) have been installed in the unix$boot tree and the HSI binary file driver was modified to add VMcache client support. This adds two new capabilities to the driver: 1) built-in support for direct i/o (on systems that support it), and 2) a client interface to the VMcache daemon to permit the daemon to optimally manage binary file i/o if a VMcache daemon is present.

The vmcached code is complete but only enough debug/testing was done to support development of the VMcache client interface for IRAF (the vmcached code is debugged but the new version of the vmcache library code has not been tested). Since the daemon can be utilized outside the normal IRAF release we do not have to fully develop it for the release.

It should be stressed that VMcache is only useful or warranted for systems that are very data intensive. The standard host operating system file access heuristics are best for "normal" processing where either the system is not really busy, or the datafiles are not excessively large. On systems with very large physical memories where massive amounts of data are being processed, VMcache can make a significant difference in overall system performance.

VMcache is too complex to document here. Without going into the details, its function is to manage a cache of files in system virtual memory. Files can be explicitly cached or uncached, or they can be "accessed", and VMcache will decide whether or not to cache the file in virtual memory. This is what the VMcache client interface does: every time it accesses (opens or extends) a file larger then the VM threshold it sends an "access" directive to the VMcache daemon. The daemon sends back a response of 0 (file not cached; use direct i/o to access the file), or 1 (file cached in VM; use normal VM-buffered i/o to access the file). Even if a file is not cached the daemon keeps track of all accesses. Files which are frequently accessed will have a higher prority and are more likely to be cached in memory.

The VMcache daemon is a separate system-level program outside of IRAF. This is necessary to provide a central system-wide cache controller. It also provides flexibility, allowing multiple versions of the daemon to exist, e.g., to allow experimentation with different types of caching algorithms. It also allows easy customization of the daemon independently of the IRAF applications using the VMcache client interface.



8.4 New Developer Libraries

Several new libraries are now available for developers:

      PSIO      New Postscript text generation library installed in the
                sys$psio.  The PSIO interface is used to format a block of
                text as Postscript output on a page of a given size (Letter,
                Legal, A4 or B5).  See the psio$README file for details.

      CATQUERY  Remote astrometric/photometric catalog access lib installed
                in the XTOOLS utility library.  
                  The catquery package provides a set of routines for local
                and remote catalog and image survey server access.  The sup-
                ported catalogs and image surveys are described in records
                stored in a catalog and image survey configuration file
                respectively. The catalog and image survey records specify
                the network address, the query format, and the output format
                for each supported catalog or image display server.  See
                "help catalogs" and "help surveys" for details.

      SKYWCS    Sky coordinate transformation library installed in the XTOOLS
                utility library.
                  The skywcs package contains a simple set of routines for
                managing sky coordinate information and for transforming from
                one sky coordinate system to another. The sky coordinate
                system is defined either by a system name, e.g.  "J2000",
                "galactic", etc., or by an image system name, e.g. "dev$ypix"
                or "dev$ypix world".




9. System Changes Which May Affect You

          IMIO_BUFSIZE      Size of the FIO buffer size in bytes.

          IMIO_BUFFRAC      FIO buffer size expressed as a percentage of 
                            the image size.  Actual value will be at least
                            BUFSIZE and no more than BUFMAX.

          IMIO_BUFMAX       Max size of FIO buffer which will override the
                            32Mb default.

Other miscellaneous environment variables:

          disable_wcs_maps  If defined or set to 'yes', this variable will
                            force any tasks which interact with the image
                            display to use the old protocols.

          pspage            Variable which is used by the PSIO interface to
                            set the default page size.  Acceptable values
                            include "letter" (the default) for US Letter,
                            "legal" for US Legal, and "a4" and "b5" for the
                            most common European sizes.  Pspage can be used
                            by the new HELP and LROFF tasks to automatically
                            set the desired Postscript page size.