Spitzer Documentation & Tools
IRSCLEAN Manual

2         Installing IRSCLEAN

2.1       Downloading

The IRSCLEAN distribution can be downloaded as a .tgz (tar-gzip) file from

 

http://irsa.ipac.caltech.edu/data/SPITZER/docs/dataanalysistools/tools/irsclean/downloadirsclean/

2.2       Unpacking

Unpack using tar -xz or another appropriate software into a directory that is either in your IDL path, or in a directory that will be added to your IDL path (see below). The distribution will create its own directory (eg., IRSCLEAN2.1/). For example, to unpack in /home/myself/idl/IRSCLEAN2.1 (assuming the directory /home/myself/idl exists):

 

unix% tar -xvzf irsclean2.1.tgz -C /home/myself/idl/

 

Note: Campaign Rogue Pixel Masks The campaign rogue pixel masks are automatically packaged with irsclean, so you no longer have to install the files yourself.  The files are located in a subdirectory all_campaigns_roguemasks/ under the IRSCLEAN2.1/ distribution, and will be picked up automatically when keyword /CampaignRMask is invoked.  The appropriate campaign mask is also automatically pre-loaded as the default input rogue mask file (inRmaskFile), if no file is given at the command line. 

2.3       Setting the IDL Path

For IDL to be able to automatically compile and run the IRSCLEAN distribution when the routines are called, either your current IDL working directory has to be the directory where IRSCLEAN resides, or the distribution must be in the IDL path. If IRSCLEAN is placed in a directory which is already in the IDL path, then make sure the path entry is set such that subdirectories are searched, via the "+" symbol.

 

To add the exact directory where IRSCLEAN resides to the IDL path, you have three options:

2.3.1        Outside of IDL, Unix-type Computers

Add the directory where IRSCLEAN resides to the $IDL_PATH environment variable in your Unix startup file.

 

For example (csh or tcsh):

 

unix% setenv IDL_PATH ${IDL_PATH}:"+/home/me/idl/IRSCLEAN2.1"

 

The "+" at the beginning of the path means "search subdirectories".

2.3.2        Inside of IDL

Use the command PREF_SET in IDL.

 

Under Unix:

 

IDL> PREF_SET, 'IDL_PATH', '<IDL_DEFAULT>:+/home/me/idl/IRSCLEAN2.1',$              /COMMIT 

     

Under Windows:

 

IDL> PREF_SET, 'IDL_PATH', '<IDL_DEFAULT>;+C:\home\me\idl\IRSCLEAN2.1'

IDL> PREF_COMMIT 

     

Note the use of the colon (";") as a path separator for Windows, and the separate call to PREF_COMMIT.

 

You can find out the current value of IDL_PATH by typing

 

IDL> PRINT, PREF_GET('IDL_PATH')

2.3.3        All IDL Versions, all Operating Systems

Use the Preferences Dialog in IDLDE.

 

The IDL Workbench (was the IDL Development Environment) (command line: idlde) graphical user interface can be used to set permanent IDL preferences. Choose File->Preferences->PATHS and add an entry to the path similar to one of the strings above. Instead of the plus sign, a check box is used to search all subdirectories.

2.4       Mac OS X: Enabling Mouse Cursor Input

By default, "click through" events are not enabled in Mac OS X. As a result, interaction between the mouse cursor and the IDL graphics window (the heart of the mask editing process) will not occur. To fix this, type the following in an X11 command line terminal:

2.4.1        In OS X 10.4 (Tiger) and prior:

unix% defaults write com.apple.x11 wm_click_through -bool true

 

Then close X11 and restart.

 

If for any reason you need to undo this, simply type

 

unix% defaults delete com.apple.x11 wm_click_through

 

Then close X11 and restart. Your original default will be restored.

 

2.4.2        In OS X 10.5 (Leopard) and later:

After OS X Leopard, use the command:

 

unix%  defaults write org.apple.x11 wm_click_through -bool true

 

to invoke click through events, and

 

unix%  defaults delete org.apple.x11 wm_click_through

 

to turn them off.  (The difference between Tiger and Leopard is the string "com" in Tiger and "org" in Leopard.) 

 

2.4.3        Emulate a three-button mouse

Another problem that Mac users may encounter is the single-button mouse. Fortunately, X11 for the Mac allows you to emulate a three-button mouse. Under X11 choose

X11->Preferences->Input->Emulate three button mouse.