next up previous contents index
Next: Correction Commands Up: 4.3 Preparation Command Syntax Previous: Projection Command Files

Projection Pipelines

 

      A pipeline is a sequence of one or more Projection commands, not longer than 256 characters, which is supplied to the MIDAS prompt. A pipeline is generally equivalent to a Projection command file containing the same sequence of Projection commands. Therefore everything has been described in section 4.3.1 and 4.3.2 about the Projection command syntax is still valid in pipelines, with the following extensions, exceptions and modifications:          

Extensions
\

Exceptions
\

Modifications
\

Here some examples of pipelines are given:

Midas 001> SELECT TIME  10000 to 20000 inp=events out=interval
Midas 002> SELECT TIME >10000 SELECT TIME <20000 *events *interval
Midas 003> SEL TIME 1000,2000 SEL AMPL 11,250 BIN/IMA 30 *events *image
Midas 004> SELECT/RING center = (0,0) radius = 50 i=events o=output
Midas 005> COUNT/BOX (-100,-100) to (100,100) input=events
Midas 006> SELECT/INTERVAL 50,200 BIN/IMAGE 30 *events,rate *out_image

Note that the first two pipelines get the same effect.                  

The reader of the previous sections can recognize the single Projection commands which compose the pipelines in the examples. The INPUT command lines are replaced in some examples by the first star (*) in the pipeline, while a second star is equivalent to the string ``OUTPUT to'' in a Projection command file. In the other examples the alternative forms i[nput]=, o[utput]=, are used instead. The usage of the stars is useful in long pipelines (remember the limit of 256 characters!).

The parameter lists in a spatial SELECT command which appears in a pipeline can be replaced by the word CURSOR whenever a reference image is loaded into the image-display window. In this case the user will be prompted for cursor input as specified in the following:    

SELECT/BOX cursor:
The box cursor appears on the image-display window. The mouse is used to position the cursor, the arrow keys are used to modify its dimensions. A ``click'' with the leftmost mouse key, or a hit to RETURN, will define the box to be selected on the sky.

SELECT/RING cursor:
The mouse is used to position the cursor, the arrow keys and the F1, F2 and F4 keys are used to modify its dimensions. A ``click'' with the leftmost mouse key, or a hit to RETURN, will define the circle (or the annulus) to be selected on the sky. It is also possible to define in advance the inner and the outer radius of the cursor via the keyword PRJ_RAD: this is a two elements MIDAS keyword, that can be modified interactively (normally it is used by the system to ``remember'' the cursor shape between calls to SELECT/RING cursor). In this way only the cursor position need to be defined via the mouse.

SELECT/SECTOR cursor:
The cross cursor appears on the image-display window. The first ``click'' with the leftmost mouse key, or a hit to RETURN, defines the sector center. The next two ``clicks'' define the start and the end angles delimiting the sector.

            The usage of squared brackets in the definition of multiple parameter lists is allowed also in pipelines, even when the parameter lists are replaced by the string cursor.

In the following example the user is prompted twice for the definition of a ring-like spatial selection with the cursor:

Midas 007> SELECT/RING [cursor][cursor] BIN TIME 10 *events *rates

The two photon lists which result from the spatial selections are binned separately in two light curves with binsize 10 seconds, and written to the table rates.tbl at the columns COUNTS_1 and COUNTS_2.

In the next example, the user is prompted first for a box selection, and then for a sector selection:

Midas 008> SEL/BOX cursor SEL/SECT cursor BIN/IMAGE 30 *events *out_image
                   

One more: with the following pipeline three spectra are produced from different portions of the sky -- just three mouse ``clicks'' would do the job:

Midas 009> SELECT/BOX [CURSOR][CURSOR][CURSOR] BIN AMPL 1 *events *spectra
                 

Up to 15 files in simultaneous output are allowed. In the next pipeline the production of three images at different energy ranges is shown:

Midas 010> SEL AMP [11,50][51,150][>150] BIN/IMA 30*events*ima1,ima2,ima3
         

Finally, a few examples with the anomalous Projection commands COUNT and SELECT/ INTERVAL which can be used only at the beginning of pipelines.    

The COUNT command syntax is identical to the one of the SELECT command. The only difference, in the COUNT pipeline no output filename needs to be defined because the only output from the counting is a number, i.e. the number of photons which have been selected. This number is (or these numbers are, in case of parallel counting) displayed to terminal and written to the MIDAS keyword OUTPUTR. Not even the BIN command is allowed in the COUNT pipeline: there is nothing to be binned.      

Here some examples of COUNT pipeline are given: their meaning should be obvious.

Midas 011> COUNT/RING cursor input=events
Midas 012> COUNT/RING [cursor][cursor][cursor] input=events
Midas 013> COUNT TIME 1000,2000 SELECT/RING CURSOR in=phot_list
Midas 014> COU AMPL >50 SEL TIM <100 SEL/BOX (100,100),(200,200) *inp_list

    Also the SELECT/INTERVAL Projection command can be used only at the beginning of pipelines. Pipelines starting with this command require two input files: a photon event list and an EXSAS reference file containing a time sequence of a given quantity (for instance, a light curve, or a column of the table eventrates.tbl). Only the photons belonging to time intervals where the reference time sequence shows a value within the specified range will be selected. Let's consider the following sequence of pipelines:

Midas 015> SELECT/RING (0,0),500 input=events output=source
Midas 016> BIN TIME 10 in=source out=rate
Midas 017> SELECT/INTERVAL 200,300 BIN AMPL 1 *source,rate,:COUNTS_1 *out
                     

In the example the light curve which is going to be used as comparison in the SELECT/ INTERVAL command is created first from the photon list contained in the table source.tbl, which includes photons coming from a given circle on the sky. The output file, rate.tbl, is input to the SELECT/INTERVAL pipeline together with the source.tbl photon list. The photons are selected within the time intervals where the time bins in rate.tbl have a value in the range 200-300 counts.

Beware: no squared brackets, no ``to'' strings, no multiple intensity intervals and other fancy options are allowed within the SELECT/INTERVAL command. In order to avoid trouble, just follow the syntax described in Table 4.4. A graphic overview on the Projection command syntax is given at this chapter end.


next up previous contents index
Next: Correction Commands Up: 4.3 Preparation Command Syntax Previous: Projection Command Files

If you have problems/suggestions please send mail to rosat_svc@mpe-garching.mpg.de