next up previous 256
Next: Global parameters with Sets
Up: Set processing multiple image instruments
Previous: Removing Set headers


Examining Set headers

For the most part, once you have added Set headers to your image files using MAKESET you will be able to let them take care of themselves. However, you may wish to check how images are related to each other, or to pull out only members of a given Set or images which correspond to each other from different Sets. For these purposes the

application is provided.

In its simplest mode of operation, it will show you the Set headers of a list of images, grouped by Set Name or Set Index. Here is a simple invocation, showing the result of the example in Section [*]:

% showset 'conv-obs?' reset 

    SHOWSET
    =======
  6 input NDFs accessed using parameter IN
  Selection excludes NDFs with no Set headers.


 Set name  Set index   NDF name                                CCD_SET frame
 --------  ---------   --------                                -------------
 conv-obs1:
           1           conv-obs1.HDU_1                               no
           2           conv-obs1.HDU_2                               no
 conv-obs2:
           1           conv-obs2.HDU_1                               no
           2           conv-obs2.HDU_2                               no
 conv-obs3:
           1           conv-obs3.HDU_1                               no
           2           conv-obs3.HDU_2                               no

  Namelist written to file: showset.lis
As you can see, it gives very similar output to that written by MAKESET when the headers were being added. If you prefer to corresponding images from different Sets grouped together, then change the LISTBY parameter (which defaults to `NAME'):
% showset 'conv-obs?' listby=index reset

    SHOWSET
    =======
  6 input NDFs accessed using parameter IN
  Selection excludes NDFs with no Set headers.

 Set index Set name                    NDF name                CCD_SET frame
 --------- --------                    --------                -------------
 1:
         conv-obs1                     conv-obs1.HDU_1               no
         conv-obs2                     conv-obs2.HDU_1               no
         conv-obs3                     conv-obs3.HDU_1               no
 2:
         conv-obs1                     conv-obs1.HDU_2               no
         conv-obs2                     conv-obs2.HDU_2               no
         conv-obs3                     conv-obs3.HDU_2               no

  Namelist written to file: showset.lis

As well as showing the Set information of all the files presented, SHOWSET is also able to select a sublist of input files according to the values in their Set headers. By supplying the PICKINDEX and/or PICKNAME parameters, images can be selected according to the values of their Set Index and/or Set Name attributes respectively. The default value of PICKNAME is `ALL', meaning that any Set Name will be selected for output. However, if PICKNAME is set to `EQUAL', then the NAME parameter gives a list of Set Name values and only images whose Set Name appears in this list will be selected. If PICKNAME is set to `LIKE', then the NAMELIKE parameter gives a list of other images to act as templates, and only images whose Set Name is the same as that of one of the template images will be selected. The PICKINDEX, INDEX and INDEXLIKE parameters work in the same way for Set Index values. Returning to another example in the previous section, we can pick out only those images in the same Set as (i.e. having the same Set Name attribute as) im12 but which have Set Index of 1 or 2 as follows (in this case some of the parameters are input as the response to prompts):

% showset 'im*' pickindex=equal pickname=like listby=none

    SHOWSET
    =======
  12 input NDFs accessed using parameter IN
NAMELIKE - Template NDFs for Set Name value > im12
  1 NDF accessed using parameter NAMELIKE
INDEX - Acceptable Set Index values > 2,3
  Selection restricted to Set Name values: im10
  Selection restricted to Set Index values: 2
                                            3

 Set index Set name                    NDF name                CCD_SET frame
 --------- --------                    --------                -------------
 2       im10                          im11                          no
 3       im10                          im12                          no

  Namelist written to file: showset.lis
Here we have also set the LISTBY parameter to `NONE', which does no grouping and lists the images in their input order.

As it points out, SHOWSET writes a list of the images it has output to a file given by the NAMELIST parameter, by default showset.lis. In the above case that list would read:

# SHOWSET - selected NDF name list
im11
im12
This file can be used with the indirection character (`$^\wedge$') to provide input for any other CCDPACK program, so you can write scripts with commands which will operate only on members of certain Sets or certain Index values. For example, you could subsequently use DRAWNDF to display the outlines of the images that the above command has selected like this:
% drawndf in='^showset.lis' clear lines



next up previous 256
Next: Global parameters with Sets
Up: Set processing multiple image instruments
Previous: Removing Set headers

CCDPACK
Starlink User Note 139
Peter W. Draper, Mark Taylor, Alasdair Allan
1 February 2006
E-mail:ussc@star.rl.ac.uk

Copyright © 2008 Science and Technology Facilities Council