HIFI useful scripts PlugIn (HI-PI)

Introduction

The NHSC collected scripts from various sources around the HIFI ICC that proved useful to users when reducing their data. This software has been packaged up in the format of a HIPE plugin, which was easy to install and auto-updated when a new version of the plugin was available.

The software is provided "as-is." Software written specifically for this plugin should work without issue. To facilitate learning, NHSC included scripts from DP training sessions. These may not work for certain versions of HIPE, but they are useful for those wanted to know how to code their own scripts for HIFI data processing.

Many of the scripts/tasks from Version 1 were integrated directly into HIPE, so they were removed from the plugin.

List of Tools

In the table below, "tasks" appear in the Applicable Task View of HIPE and are typically invoked by double-click so that they present their parameters in a GUI. "Scripts" are listed in the TOOLS→PLUGINS→HIPI menu item.

Task Name Category Format Desription
clearHifiFlags flags task Allows for the bulk clearing of flags in any HIFI observation
setHifiChannelFlags flags task Set channel flags via frequency.
setHifiRowFlags flags task Set row flags more easily
pointingPlot pointing script Plot the position of all science data in an observation
readClassFits import script Allows HIPE to read in a .fits file created by GILDAS/CLASS.
SaveObsLevelToClass export script Save an obs level to CLASS format.
ProcessRefPosition data quality script Allows the user to deconvolve the "reference" spectrum.
FlagSpectraWithColumnValueOverThreshold flags script Flag spectra with an extreme column value.

Additionally, the scripts from the September 2013 workshop are included. To get the most out of them, you need the test data and ancillary files from the webinar page.

Documentation

clearHifiFlags

This task will clear the SUSPECT_LO and IGNORE_DATA row flags from all data in a given HTP. It also clears the following channel flags: PUR_CANDIDATE, LINE, BRIGHT_LINE, IGNORE_DATA. By default all data is cleared. The optional parameter 'idx' can be used to specify a single dataset to clear. 'idx' is the value shown in the hifiFlagViewer, and it corresponds to the position of the data within an HTP.

By using the optional parameters 'skipRowFlags=True' or 'skipChannelFlags=True', the user can choose to clear one type of flag while preserving the other.

setHifiChannelFlags

This task simplifies setting the channel flags in a HIFI HTP. Given a dataset index and a start/stop frequency, the task will set the IGNORE_DATA flag for all relevant channels in the dataset. The user can optionally set another flag if they wish by using the 'flagValue' parameter. It is up to the user to enter a frequency range in the same units as the data. The task will issue a warning if no match was found.

setHifiRowFlags

Given an htp and an index, this task will set the IGNORE_DATA row flag for the dataset. Alternate row flags can be given via 'flagValue', but this is not recommended.

pointingPlot

Simply plots the position of science data in a graph. Can be slow on long observations.

readClassFits

Allows HIPE to read in a .fits file created by GILDAS/CLASS. It works only on .fits files with a single spectra. (Written by Russ Shipman, modified by David Teyssier).

SaveObsLevelToClass

Save an obs level to CLASS format. Written by Ronan Higgins.

ProcessRefPosition

Allows the user to deconvolve the 'reference' spectrum made by mkDbsRef. Useful for spectral scans where one suspects flux in one of the reference positions. Written by Ronan Higgins.

FlagSpectraWithColumnValueOverThreshold

Flag spectra with an extreme column value. Column can be mixer current or any column available at the dataset level. Written by Ronan Higgins.

Download

Download 2.1 (.jar).

For installation of the plug-in:

  1. Open HIPE and under menu point "Tools" the entry "Plugins."
  2. Click "Install new plug-in" in the new window.
  3. Either supply the URL of the plugin or download the plug-in and use the file selector dialog to provide its location on disk
  4. Restart HIPE and check the Plugin area to see if HIPI is listed (Tools→Plugins).
Version Date Changes
1.0 May 29, 2012 Initial Release
2.0 Sept. 5, 2013 Updated for HIPE 11+
2.1 Sept. 12, 2013 Added a few more utility scripts from the ICC.