1.109. mkSpur

Full Name: herschel.hifi.pipeline.wbs.MkSpurTask
Alias: mkSpur
Type: Java Task - Java Task
Import: from herschel.hifi.pipeline.wbs import MkSpurTask

HIFI/Pipeline/WBS Pipeline


A task to identify spurs in WBS HTPs

This routine will loop through all hot/cold datasets in a HifiTimeLineProduct and catalog spurs. It is best run after the WBS branch but before the generic pipeline. The algorithm used is as follows.

First, all fluxes above the saturation threshold are flagged. The routine then determines the width of each saturated region, cataloging them as they are found. A region larger than the saturated pixels is flagged as bad, since the wings of the spur are not saturated yet clearly part of the spur. The excess region flagged is 75% the width of the spur on either side of it.

Next, the second derivative of the flux is calculated and its RMS determined. Using a threshold of sigma*RMS, the point in the second derivative that deviates the most is found, and a Gaussian is fit to the original flux. The spur is flagged, and then the process repeated for other points in the second derivative until none are found that deviate more than the threshold.

The spurs are returned as a table dataset, and flag column in each hot/cold dataset in the HTP are set appropriately.


Example 1: Simple example.
spurTable = mkSpur(htp)

API details


HifiTimelineProduct htp [INPUT, MANDATORY, default=No default value]

The HTP to process.

Double threshold [INPUT, OPTIONAL, default=750]

The flux above which the WBS is considered saturated.

Double sigma [INPUT, OPTIONAL, default=10.0]

The threshold used to determine if something is a spur is given by sigma*X, where X is the RMS of the second derivative of the flux. The default of 10.0was determined from TV/TB and Gascell observations

Double fwhm [INPUT, OPTIONAL, default=15.0]

Spurs are fit using a Gaussian profile. The initial guess at the width of the spur is given by this variable. The default of 15 was determined from TV/TB and Gascell observations.

CalSpur result [OUTPUT, OPTIONAL, default=No.]

The list of spurs

See also


  • 2011-06-15 - AL: changed name from MkSpur to MkSpurTask