; CYG
;---------------------------------------------------------------
;! verifies correctness and performance using standard problems
;# RUN GENERAL
;-----------------------------------------------------------------------
;;  Copyright (C) 2003
;;  Associated Universities, Inc. Washington DC, USA.
;;
;;  This program is free software; you can redistribute it and/or
;;  modify it under the terms of the GNU General Public License as
;;  published by the Free Software Foundation; either version 2 of
;;  the License, or (at your option) any later version.
;;
;;  This program is distributed in the hope that it will be useful,
;;  but WITHOUT ANY WARRANTY; without even the implied warranty of
;;  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;  GNU General Public License for more details.
;;
;;  You should have received a copy of the GNU General Public
;;  License along with this program; if not, write to the Free
;;  Software Foundation, Inc., 675 Massachusetts Ave, Cambridge,
;;  MA 02139, USA.
;;
;;  Correspondence concerning AIPS should be addressed as follows:
;;         Internet email: aipsmail@nrao.edu.
;;         Postal address: AIPS Project Office
;;                         National Radio Astronomy Observatory
;;                         520 Edgemont Road
;;                         Charlottesville, VA 22903-2475 USA
;---------------------------------------------------------------
CYG       LLLLLLLLLLLLUUUUUUUUUUUU CCCCCCCCCCCCCCCCCCCCCCCCCCCCC
CYG  :  Verification/timing test; see CYGLOAD.001, CYGEXEC.001
TCODE                              INIT, TEST, READ, or WRIT
TMODE                              T or M; Test or Master input
TMASK           1.0       127.0    test selection bit mask
Y2KSIZE                            SMALL, MEDIUM, LARGE test
DDISK           1.0        35.0    Disk drive #: master UVDATA
MDISK           1.0        35.0    Disk drive #: other masters
TDISK           1.0        35.0    Disk drive #: test images
IOTAPE          1.0         9.0    Input/Output tape drive #.
Y2KDISK                            Disk area for READ and WRIT
EDGSKP          0.0        64.0    Pixels to skip at edges
TERSE          -1.0        99.0    > 0 => reduced output
OUTPRINT
                                   Printer disk file to save
BADDISK                            Disks to avoid
VERSION
----------------------------------------------------------------
CYG
Type: RUN file
Use:  CYG performs the AIPS verification test on an AIPS system.
      See RUN files CYGLOAD.001 to compile a set of procedures and
      CYGEXEC.001 to run them.  This input file is used to prepare the
      parameters needed to run CYGEXEC.  Set the adverb values, do a
      TPUT CYG, and then RUN CYGEXEC.

      The idea is to run a sequence of the most commonly used tasks in
      AIPS on a standard UV data set.  The tasks are UVSRT, IMAGR,
      APCLN, CALIB, and VTESS as the main tasks with tasks SUBIM,
      COMB, UVDIF, CCMRG, FITLD, and FITAB also being exercised.  The
      test runs each task and compares the results with standard
      answers prepared when the test was devised or last revised.  The
      total time it takes to execute may be used to compare computer
      performance and the degree to which the current answers agree
      with the official answers compares compilers/computers and code
      reliability/constancy.
Adverbs:
 TCODE    String*4      'INIT' - create new master files
                        'TEST' - test tasks against master files
                        'READ' - read master files from tape/disk
                        'WRIT' - write master files to tape/disk
                        User sites would first READ the master files
                        in and then TEST them.
 TMODE    String*1      'T' - test output from previous task used as
                              input to next task.
                        'M' requests master input to all tasks.
 TMASK    Scalar        Task selection bit mask (1-63) - use 63
                        normally.
                        TMASK +1=>IMAGR,  +2=>IMAGR-Clean,
                        +4=>CALIB-P,  +8=>IMAGR-Clean, +16=>CALIB-A&P
                        +32=>IMAGR-Clean
 Y2KSIZE  String*8      'SMALL', 'MEDIUM', 'LARGE' test.  The LARGE
                        test is used to measure performance.
 DDISK    Scalar        Disk drive # (1-9) master UVDATA
 MDISK    Scalar        Disk drive # (1-9) other master files
 TDISK    Scalar        Disk drive # (1-9) test files
 IOTAPE   Scalar        Input or output tape drive #. (1-9)
 Y2KDISK  String*8      Logical name of disk area to be used for
                        FITS-disk files in READ or WRIT instead
                        of actual magnetic tape.
                        ' ' => use magnetic tape.
 EDGSKP   Scalar        Number of pixels to skip at edges in
                        comparing test and master images
 TERSE    Scalar        > 0 => reduced output:
                          > 0 = drops INPUTS for all tasks and
                                TPHEAD when reading tape
                          > 2 = also drops CATALOG listings
                          > 3 = also drops IMHEADER listings
                        Use -1 on all new or uncertain systems, or
                        when determining the AIPSMark.
 OUTPRINT String*48     Disk file name in which to save the line
                        printer output.   ' ' => use scratch and
                        print immediately for interactive jobs -
                        batch jobs use OUTPRINT =
                        'PRTFIL:BATCHjjj.nnn' (jjj = job #, nnn
                        = user #).  When OUTPRINT is not blank,
                        multiple outputs are concatenated and
                        the file is not actually printed.
 BADDISK  Array         Any bad disks to avoid for scratch files
 VERSION  String*48     Version of tasks to use - normally blank to
                        use TST.  Other values include OLD, NEW, and
                        private dirs; use | to separate entries in a
                        search path.

CYG runs in four different modes: (TCODE)
   INIT = starts from the original master UV dataset, and
           (re)computes master files (does ALLDEST).
           The "mask" TMASK controls which steps execute.
   TEST = re-does the INIT computation but stores the new
           files under different names and compares against
           masters. The "mask" TMASK controls which steps
           execute. TEST steps use either the TEST run output
           of the previous step (TMODE=T) or the INIT run
           output (TMODE=M).
   WRIT = write master or test files to tape (TMODE matters)
   READ = read master files from tape.

Input data files for test steps are selected by the TMODE
   adverb which has two possible values: 'T' for those made
   in previous steps of the present test or 'M' for the
   master "correct" data sets input from tape.

The adverb Y2KSIZE controls the size of the test performed:
   'S'    1024x1024 image, 15000 clean components, 75000 vis
   'M'    2048x2048 image, 25000/75000 Clean components,
          425000 vis
   'L'    3-facet, 4 resolution 2048x2048 and 4096x2048
          35,000 and 70,000 and 210,000 CCs,   2674383 vis
----------------------------------------------------------------
