IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changes between Initial Version and Version 1 of IppTools_FAQ


Ignore:
Timestamp:
Feb 24, 2009, 4:23:57 PM (17 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • IppTools_FAQ

    v1 v1  
     1This would be a good place to put info on using the ippTools.
     2
     3Links to all FAQ pages : [wiki:FAQ FAQ]
     4
     5=== skycells ===
     6(not technically an ippTool... perhaps this should be filed somewhere else?)
     7
     8After the astrometric solution has been applied to a set of images,  you are ready to warp those images onto the sky.  To do that, you first must subdivide the sky into skycells.  Each skycell is simply a rectangular projection of some fraction of the sky onto a flat plane. The IPP defines skycells using a tesselation of triangles with common bases.  The center of each triangle defines the center of a skycell.   To create a more finely spaced grid of skycells, one can divide a triangle into three new triangles with interior lines extending from the vertices to the center.  With each level of triangle division, your skycells get smaller and the planar approximation of a spherical surface gets a little better.  Once you have defined a rectangular patch of sky with a suitable number of triangle divisions, you may chop that rectangle into smaller rectangles with divisions in the x and y directions.
     9
     10To define your tessellation of the sky, use the <code>skycells</code> program.  Type <code>skycells -h</code> to get a list of options.   The -level option sets the number of triangular subdivisions to use in the tessellation. If this option is omitted, <code>skycells</code> will use the SKY_DEPTH parameter from your .ptolemyrc file.   Here is an example that was used to define the FIXNS tessellation pattern, intended for the GPC1 MD field data:
     11
     12  skycells -level 5 -scale 0.2 -nx 8 -ny 8 -fix-ns -padding 0.05
     13
     14Here we have done 5 iterations of triangle divisions and we have set the pixel scale of the resulting cells to 0.2 arcsec/pixel.  Each rectangular patch of sky is then divided into 64 skycells, with 8 divisions in x and y.  The <code>fix-ns</code> command indicates that the y axis of every cell is oriented with Dec, and there is a 5% padding of each skycell to ensure sufficient overlap with neighbors.   The result is a catalog that defines all the skycells necessary for filling the sky, stored in the files Images.dat and Photcodes.dat.    Use the "-D CATDIR <dir>" option to specify the directory where Images.dat and Photcodes.dat should be written. The default is to make a subdirectoy called "default" in your cwd.
     15
     16After you've created the Images.dat and Photcodes.dat catalogs, be sure to point to them in your camera.config file:
     17
     18 TESSELLATIONS   METADATA
     19       # Tessellation name with corresponding DVO catdir
     20      MYSKYCELLS        STR     /path/to/catdir
     21 END
     22
     23
     24Here are a few more examples of skycells commands from elsewhere on the wiki:
     25
     26 * tessalations for PR images:
     27 skycells -D CATDIR skycells.4n.M31 4 -fix-ns -euler 1.5 1.8 -nx 6 -ny 6 -scale 0.333
     28 skycells -D CATDIR skycells.4n.Holmes 4 -fix-ns -euler -0.1 -0.5 -nx 6 -ny 6 -scale 0.333
     29
     30 *Sebastian's LBC reductions
     31 skycells 6 -scale 0.2 -fix-ns -D CATDIR /disk1/jester/data/LBT/z7qso/sci/skycells
     32
     33 * ESSENCE testing
     34 skycells -D CATDIR skycells 8 -scale 0.2
     35
     36----
     37
     38=== Labels ===
     39
     40====setting====
     41With any of the ippTools, you can (and should!) use labels to separate your data into processing groups.  When you define a chipRun, camRun, or any other run, the <code>-set_label</code> option allows you to provide a string to label all the processes that your ippTool creates. The label is then carried along to child processes as you step through subsequent stages of the IPP.  For stages that are downstream of your initial labeled process, you may select the labeled outputs using the <code>-label</code> option.
     42
     43For example, you can set up a chipRun with just the g-band MD01 exposures:
     44
     45<code>chiptool  <font color=green>-set_label MD01.g</font> -set_workdir /data/ipp004.0/gpc1/MD.SR -dbname PS1MD -definebyquery -ra_min 0.6 -ra_max 0.645 -decl_min -0.08 -decl_max -0.07 -exp_time_min 200 -filter g.00000 -simple</code>
     46
     47and then later on  (after initiating several other chipRuns for other fields and filters) you want to make a stack from all those exposures that you labeled with MD01.g:
     48
     49<code>stacktool -workdir MD.SR -dbname PS1MD -definebyquery <font color=green>-select_label MD01.g</font> -simple</code>
     50 
     51====blocking====
     52If you have been consistently applying labels as you inject your data or as you start your chip processes, then you can efficiently use the ippTools label-blocking feature to select out just a particular subset that you do (or don't) want to process right away.  In any ippTool, use the <code>-block</code> option to set a block on a particular label.  Use <code>-unblock</code> to remove that block.  The <code>-masked</code> and <code>-unmasked</code> options will print out a list showing which exposures are carrying what labels, and whether or not they are currently being blocked from processing. 
     53
     54 
     55----
     56=== chiptool ===
     57----
     58=== camtool ===
     59----
     60=== warptool ===
     61----
     62=== stacktool ===
     63
     64Stacktool is used to set up a stackRun, which creates a stack of overlapping images and sums them together.   A single stackRun can create multiple stacked skycell images, by selecting the warped images that meet your specified criteria, finding all the skycells that those warps contribute to, and summing up each pile of skycell images individually.   If you specify a skycell_id, of course, you will only stack on that skycell.
     65
     66Most of the major modes are similar to modes from other ippTools.  The most commonly used modes are discussed here.
     67
     68====-definebyquery====
     69
     70You must define a workdir with <code>-workdir</code>.  It is recommended to use <code>-label</code> to keep things organized. 
     71
     72use the <code>-select_</code> options to pick out the warped skyfiles you want to combine.  The <code>select_good_frac_min</code> option requires that each contributing skyfile has to have that fraction of its area with good pixels.
     73
     74<code>-random</code> : if your <code>select</code> settings return a large number of skyfiles, then you may not want to stack them all together.  The random flag allows you to pick out a random subset from the collection of all matching skyfiles.
     75
     76<code>-min_num</code> : you may only want to execute the stack when it has a certain number of contributing skyfiles.  Specifying the -min_num option tells stacktool to return an empty set unless it has at least min_num skyfiles.
     77
     78<code>-min_new</code>  : ??
     79
     80<code>-min_frac</code> : ??
     81
     82
     83====-updaterun====
     84
     85As of 2008-09-18  on ipp-2.6.1 this can only change the state.  Use 'new' to make it a pending job in the pantasks queue.  Use 'full' to indicate successful completion.   Any string is valid.
     86
     87====-revertsumskyfile====
     88
     89As described above, each stackRun may create multiple summed skyfiles.  Use this mode to revert and restart any problemative summed skyfiles.
     90
     91----
     92=== difftool ===
     93
     94Set up a diffRun to create difference images by subtracting warped and/or summed skyfiles.  Each subtraction defines one image as the "template" and the other as the "input".   The difference image is '''(input - template)'''.
     95
     96==== -definepoprun ====
     97
     98Use this option to set up a pop run (populated? popular? popsicle?) where you can explicitly specify the ID of both your template and input images.  Each may be either a warped skyfile (use <code>-input_warp_id</code> or <code>-template_warp_id</code>) or a summed skyfile produced by a previous stackRun (use <code>-input_stack_id</code> or <code>-template_stack_id</code>).
     99
     100==== -definebyquery ====
     101
     102This mode searches for any possible difference matching the given criteria.  It is designed to subtract a stack (summed skyfile) from a warp (single image skyfile).    You can specify selection criteria involving either the '''input''' (warp) image or the '''template''' (stack) image, or both.