RHESSI FAQ - SSW and SSW installation


 

What does SSW IDL mean?
What does $SSW mean?
How do I install the SSW software?

What should I do if my machine hangs in the middle of the SSW installation?
During the installation, I got some error messages. Should I worry?
How can I tell if the SSW update worked?
I'm having trouble running SSW.  Should I reinstall?
How does the setup for SSW IDL differ on Windows and Unix?
What are the SSW IDL startup scripts?
Do I need my own personal IDL startup file?
How can I add an SSW instrument to SSW IDL?
How can I find out what other instruments/packages are available under SSW IDL?
How can I add my own software directories to the SSW IDL path?
How can I remove elements from the SSW IDL path?
What if the basic routines used to check the setup (like 'pr_path' or 'which') don't work?
How can I tell if I've run out of environment space?  And then what?  (Windows only)?
Where can I find documentation and source listings for SSW routines?
What is SSWDB for?
How do I install and update SSWDB?

Back to main RHESSI FAQ page

 


 What does SSW IDL mean?


SSW IDL refers to a session of IDL that has been started by running the SSW setup routines to:

These tasks are accomplished by different means on Unix and Windows.

After installing and setting up SSW, start SSW IDL by:


What does $SSW mean?


In Unix, environment variables are indicated by preceding the name with a $. There is no equivalent character on Windows. However, on both Windows and Unix, the environment variable SSW that points to the top of the SSW tree may be referred to as $SSW.


How do I install the SSW software?

Follow the instructions in the document RHESSI Data Analysis Software Installation.


What should I do if my machine hangs in the middle of the SSW installation?

During the installation, large tar files are copied from the SSW server. Intermittent network problems may cause the procedure to hang. The simplest thing to do is reboot if you can, delete the ssw directory that contains the partial installation, and restart the setup.bat procedure.


During the installation, I got some error messages. Should I worry?

You can ignore the following types of messages (this is not a complete list):

Ignore the message ‘Tried to create symlink but not supported locally’.

Ignore any messages indicating that a directory or file was already there, but is being overwritten.


How can I tell if the SSW update worked?

Look at the log file in $SSW/site/setup.  On Unix it's called update_ssw.log;  on Windows, it's usually called something like daily.log.  In this file you should see a group of lines for each SSW package you are updating.  In the group there will either be the line 'No files to transfer', or one or more lines saying 'Got xxx' showing the files that were retrieved.  If any of the packages contain words like 'Failed to get ...' or 'Fatal error talking to site...' or 'Can't build data connection...', or any other error message that looks like a failure, then you should run the update again.  When you run the update the second time, it does not need to copy files that were successfully copied the first time.

Notes:

You can't just look at the end of the update log file to see if it worked.  You have to look in the stanza for each package.

You can ignore the error messages listed here.


I'm having trouble running SSW.  Should I reinstall?

You usually shouldn't need to reinstall SSW, unless your SSW installation is completely messed up.  Usually it is a matter of reviewing your setup files.  For RHESSI, review:

on Windows:

$SSW/site/setup/setup.hessi_env file
$SSW/site/setup/sswidl.bat

on Unix:

$HOME/setup.hessi_env or $SSW/site/setup/setup.hessi_env
your .login or wherever you initialize SSW, SSW_INSTR, etc.
 


How does the setup for SSW IDL differ on Windows and Unix?

The main difference in the setup for SSW IDL is that on Unix, most of the setup is done outside of IDL, while on Windows it is done within IDL.

SSW was originally written for Unix. The scripts that set environment variables and change the IDL path are Unix shell scripts. When SSW was extended to work on Windows, IDL routines were written to read those same shell scripts and interpret them for a Windows environment. The Windows environment is actually an improvement over the Unix environment. Because the instrument setup scripts are interpreted in IDL, instruments can be added dynamically within an IDL session. On Unix, you must exit IDL, change your instrument list, rerun the scripts, and reenter SSW IDL. (The Unix environment may be modified to allow dynamic SSW reconfiguration in the future.)


What are the SSW IDL startup scripts?

Windows:

SSW IDL is started by running the batch file $SSW/site/setup/sswidl.bat (or a shortcut to it on your desktop). This script:

Unix:

Usually in your .login file, you will have lines that define $SSW, your startup routine, select SSW instruments, and run the setup scripts, similar to:

setenv SSW /ssw
setenv IDL_STARTUP $HOME/idl_startup.pro
setenv SSW_INSTR hessi spex xray
source $SSW/gen/setup/setup.ssw

If these lines are not in your .login, they are probably in a system-wide file that automatically gets run when you log on. Or, on some systems, typing sswidl automatically runs these commands before starting IDL.

On both Windows and Unix the definition of SSW_INSTR controls what further scripts will be executed. On Windows these scripts are run from within IDL by the generic IDL_STARTUP procedure, while on Unix, they are run outside of IDL by the $SSW/gen/setup/setup.ssw shell script. For each instrument selected, a script named setup.xyz_env, where xyz is the name of the instrument (e.g. setup.hessi_env), will be run if it exists. The setup files are run in the following order:

(so the files run later will override the files run earlier).


Do I need my own personal IDL startup file?

You don’t need your own IDL startup file to run the RHESSI software.

Your personal IDL startup file is run after all the other SSW IDL setup files are run. You might want to create one if you want to set personal preferences or additional environment variables. For example, if you don’t want to see all of the compile messages in IDL, and you have some local printers, your IDL startup might have the following lines:

!quiet=1
set_logenv, 'PSLASER', '\\lotus\laser-g62'
set_logenv, 'PSCOLOR', '\\lotus\hpcolor'

However you cannot put the command to add ssw instruments on Windows (setssw_windows) in the idl startup file. It will start an infinite loop. Also, defining SSW_INSTR in this file to select SSW instruments will have no effect since it is run after the other setup files.

On Windows, you can identify an IDL startup file to run in your $SSW/site/setup/sswidl.bat by setting the SSW_PERSONAL_STARTUP environment variable.  In addition, on Windows if there is a file called idl_startup.pro in your working directory, it will also be run after the SSW_PERSONAL_STARTUP file.

On Unix, to run your own startup file, you must set the environment variable IDL_STARTUP to the name of the file.  Since SSW IDL needs to run its own generic startup file, when you start SSW IDL, it appends your idl startup file to the generic startup file and saves it in your working directory in a file called ssw_idl.xxxxx.  During the IDL session, the IDL_STARTUP environment variable is temporarily redefined to point to that file.  Unless IDL crashes, the ssw_idl.xxxx file is removed when you exit. 


How can I add an SSW instrument to SSW IDL?


In order to include an instrument’s software and environment variables in your IDL session, the instrument must have been included in your initial installation of SSW on your computer.

Windows:

On Windows, you can add an instrument while in an SSW IDL session with the setssw_windows routine. For example to add hessi and trace, type:

IDL> setssw_windows, /hessi, /trace

To change the default instruments that SSW IDL starts with on Windows, edit the line defining SSW_INSTR in $SSW/site/setup/sswidl.bat: and restart IDL. The line will look similar to:

set SSW_INSTR=hessi ovsa spex xray

Unix:

On Unix, SSW_INSTR can be defined in your .login file. For example, the following line in your .login file sets the instrument list to hessi, xray, spex, and goes:

setenv SSW_INSTR ‘hessi xray spex goes’

Change this line and then rerun the SSW setup routine:

source $SSW/gen/setup/setup.ssw

and then restart SSW IDL.
 


How can I find out what other instruments/packages are available under SSW IDL?

From an SSW IDL session, type

print,ssw_instruments()

A list of all the instruments and packages available in SSW will be displayed. To add an instrument or a package from the list to your installation, you should reinstall SSW with those instruments selected, or use the ‘Upgrade existing’ option from the SSW installation pages.


How can I add my own software directories to the SSW IDL path?

Use the add_path routine. For example,

IDL> add_path, ‘e:\kim\testdir’, /expand, index=0

will expand the directory tree under the directory e:\kim\testdir and place all of those directories at the beginning of the IDL path.


How can I remove elements from the SSW IDL path?

Use the remove_path routine. For example, to remove the atest directory,

IDL> remove_path, ‘atest’

To remove all trace directories:

IDL> remove_path, ‘trace'


What if the basic routines used to check the setup (like 'pr_path' or 'which') don't work?

You don't have the basic SSW directories in your IDL path, probably because you are not really running SSW IDL. Review the installation and setup instructions for SSW IDL. To see what your path is without the help of SSW routines, type print,!path.
 


How can I tell if I've run out of environment space? And then what?  (Windows only)

If your setup looks correct, but all of the environment variables in setup.hessi_env (or another setup script) are not getting set, then probably Windows has run out of environment space. You can verify this by editing the batch file you run to start IDL (usually called sswidl.bat in your $SSW/site/setup directory). Insert a line with the word 'pause' at the end of the batch file. Then re-run the batch file. The ‘pause’ will cause the DOS window to stay open so that you can see any error messages. If the error message indicates that you ran out of environment space, follow the steps here (Windows 95,98,ME) or here (Windows NT, 2000, or XP) for changing the memory properties of your shortcut. (Press return to allow the batch file to proceed.)


Where can I find documentation and source listings for SSW routines?

There are several methods:


What is SSWDB for?

SSWDB contains various calibration and ancillary data bases in an area that is separate from the software.  The RHESSI area under SSWDB (ancillary SSW data base) has tables of smoothed modulation patterns that can speed up the pixon image algorithm by up to a factor of 2.  In the future, other types of HESSI data files will be placed in SSWDB that you will probably want to use, so you may want to install and regularly update the HESSI part of SSWDB.
 



How do I install and update SSWDB?

If you have access to a server where the RHESSI SSWDB is installed, you don't need to have a local copy. You can NFS-mount/share it on UNIX/Windows from the server, and set your SSWDB environment variable to point to the SSWDB top directory. At Goddard, the RHESSI SSWDB files are located on hesperia in /hessi/data3/sswdb. At SSL, Jon Loran has installed SSWDB (RHESSI, EIT and a few other data types) in /sswdb.

To install a local copy of SSWDB (RHESSI or any other type of data) on your computer go to the SSWDB Web page at http://www.lmsal.com/solarsoft/sswdb_description.html.  The instructions there are good for UNIX, but are not oriented to Windows, so I'll include instructions for Windows, and a few notes for UNIX. For now, you probably just want to install the 'HESSI img suport (pixons)' part of HESSI SSWDB.

On Windows:

  1. Create a directory on your machine for the SSWDB files, .e.g. c:\sswdb
  2. Make sure your definition of the SSWDB environment variable points to the directory in Step 1. SSWDB is usually defined in your sswidl.bat file. Type hessi_var to see the current settings of env variables.
  3. Goto http://www.lmsal.com/solarsoft/sswdb_configure.html and check the boxes for the data types you want to copy ('HESSI img suport (pixons)' for now)
  4. Click 'Generate SITE configuration file'.
  5. Right-click 'Your SITE configuration file' and save the file in ...ssw\site\setup\setup.sswdb_upgrade
  6. In SSWIDL, type sswdb_upgrade, /sp
  7. The SSWDB files will be placed in subdirectories under your SSWDB directory. The software will find them in their subdirectories - you don't need to explicitly point to the pixons subdirectory.
  8. To update, run sswdb_upgrade,/spawn anytime. (Note: the pixon files will not change very often.)

UNIX notes:

  1. The SSWDB variable is usually defined in the $SSW/site/setup/setup.ssw_paths on UNIX machines, but could also be in your .login or $HOME/setup.ssw_paths. Wherever you are defining it, make sure it points to your SSWDB area.
  2. On UNIX, you can use the sswdb_upgrade, /spawn command interactively in IDL, but if you normally update SSW in a cron job using go_update_ssw, this cron job will now also update SSWDB every time it runs (due to the presence of the $SSW/site/setup/setup.sswdb_upgrade file that you created).

Last updated 26 March 2012 by Kim Tolbert , 301-286-3965