IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changes between Initial Version and Version 1 of sample_pstamp_request


Ignore:
Timestamp:
Sep 10, 2009, 3:52:56 PM (17 years ago)
Author:
bills
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • sample_pstamp_request

    v1 v1  
     1
     2== Creating Postage Stamp Request Files ==
     3
     4Postage Stamp request files are FITS tables.
     5
     6We expect that various science servers and other users will have their own programs for
     7building request files.
     8
     9To help with testing the postage stamp server we have written a simple script called
     10pstamp_req_create. It may be found in the IPP source tree in the directory
     11pstamp/test.
     12
     13This script has no IPP dependencies but does use the perl module Astro::FITS::CFITSIO.
     14
     15The input to this program is a text file. For example
     16
     17
     18{{{
     19# Sample Postage stamp request description file
     20
     21# pstamp/test/asteroid.txt
     22
     23# This can be parsed by the program pstamp_req_create to build a
     24# PS1_PSTAMP_REQUEST binary table
     25
     26# First line of data is for the extension header
     27# The order of keywords follows TABLE 6 of ICD
     28#
     29# Note that value for REQ_NAME may be overriden by a command line
     30# argument to pstamp_req_create.
     31# Blank and comment lines are ignored
     32
     33# REQ_NAME EXTVER
     34CHANGEME     1
     35
     36# subsequent lines define the rows in the table
     37#
     38
     39# These coordinates get stamps from warp and diff images that show a moving object that mops found.
     40
     41# ROWNUM PROJECT       JOB_TYPE OPTION_MASK REQ_TYPE IMG_TYPE    ID      TESS_ID COMPONENT COORD_MASK CENTER_X   CENTER_Y             WIDTH HEIGHT  REQFILT MJD_MIN MJD_MAX
     42
     431        gpc1           stamp     3         bydiff   warp      362483    NULL      NULL      2       284.688522833822 -3.86916140936841 200  200     null   0         0
     442        gpc1           stamp     3         bydiff   diff      362483    NULL      NULL      2       284.688522833822 -3.86916140936841 200  200     null   0         0
     453        gpc1           stamp     1027      bydiff   warp      362483    NULL      NULL      2       284.688522833822 -3.86916140936841 200  200     null   0         0
     464        gpc1           stamp     1027      bydiff   diff      362483    NULL      NULL      2       284.688522833822 -3.86916140936841 200  200     null   0         0
     47}}}
     48
     49To create a request file is simple
     50
     51
     52{{{
     53                pstamp_req_create --input asteroid.txt --req_name bills.20090910_1 --output myrequest.fits
     54}}}
     55
     56If the -req_name parameter is omitted, the REQ_NAME given in the input file will be used.
     57
     58This file uses the 'bydiff' mode which selects the images of interest based on a diff_skyfile_id. The next file shows
     59some other modes.
     60
     61
     62{{{
     63# REQ_NAME EXTVER
     64CHANGEME     1
     65
     66# subsequent lines define the rows in the table
     67
     68# ROWNUM PROJECT JOB_TYPE OPTION_MASK REQ_TYPE IMG_TYPE    ID      TESS_ID COMPONENT   COORD_MASK CENTER_X   CENTER_Y WIDTH HEIGHT REQFILT MJD_MIN MJD_MAX
     69# warps from various epochs for one of the SN candidates. Specifiying the skycell speeds up processing
     701         gpc1   stamp      1        byid        warp     6245   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     712         gpc1   stamp      1        byid        warp     6254   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     723         gpc1   stamp      1        byid        warp     6264   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     734         gpc1   stamp      1        byid        warp     6317   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     745         gpc1   stamp      1        byid        warp     6324   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     756         gpc1   stamp      1        byid        warp     6465   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     767         gpc1   stamp      1        byid        warp     6466   null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     77
     78
     79# get a specific warp
     8010        gpc1   stamp      1        byid         warp     6316  null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     81
     82# get stamps from all warps for exposure (only destreaked ones will succeed)
     8311        gpc1   stamp      1        byexp        warp    o4973g0123o null skycell.077 2 242.400666 55.273513 200 200 null 0 0
     84
     85# get stamps from all chipRuns for exposure (only destreaked ones will succeed)
     86# add the mask and weight images as well
     8712        gpc1   stamp      7        byexp      chip    o4973g0123o null null  2 242.400666 55.273513 200 200 null 0 0
     88
     89# get the corresponding diff
     9013        gpc1   stamp      1        byexp      diff    o4973g0123o null null 2 242.400666 55.273513 200 200 null 0 0
     91
     92}}}
     93
     94Most of these request specifications only request the image (OPTION_MASK = 1).
     95An exception is row 12 which has OPTION_MASK = 7. This will request the mask and variance images as well.
     96Soon more bits of this this column will be used to select other output products (psf files for example).
     97
     98If a column with string is not required for a given request specfication, it may be given the value 'null'
     99