EOVSA Data Analysis Tutorial
- 1 Software
- 2 Spectral Imaging with SunCASA
- 3 Spectral Fitting with GSFIT
We have developed two packages for EOVSA data processing and analysis:
- SunCASA A wrapper around CASA for imaging and visualizing spectral imaging data of the Sun. More information about CASA can be found on NRAO's CASA website . Note, (Sun)CASA is ONLY AVAILABLE on UNIX-BASED PLATFORMS (sorry Windows users).
- GSFIT A IDL-widget(GUI)-based spectral fitting package called gsfit, which provides a user-friendly display of EOVSA image cubes and an interface to fast fitting codes (via platform-dependent shared-object libraries).
There are two approaches in accessing our software packages. One is through our Amazon AWS server (recommended for participants of the EOVSA tutorial at the RHESSI 18 Workshop). Another is to install them on your own machine. We discuss the first approach in Section 1.1, and the second in Section 1.2.1 (SunCASA) and 1.2.2 (GSFIT).
Using Software on AWS server
We use an Amazon AWS Lightsail server for testing purposes. The server has 2 CPUs, 8 GB RAM, and 160 GB SSD storage. It runs CentOS 7 (1901-01) Linux. Please limit your usage to LIGHTWEIGHT DATA PROCESSING ONLY.
NOTE: THE ACCOUNT IS ONLY INTENDED FOR THE EOVSA TUTORIAL, BUT *NOT* FOR CARRYING OUT ACTUAL DATA REDUCTION
- Obtain SSH Key from Bin Chen
- Put it under a secure location on your own machine.
- Follow remaining directions depending on your client machine.
Connecting via Linux / Mac
Recommend to use "~/.ssh" (create if it does not exist by "mkdir ~/.ssh").
- Edit the permission of ~/.ssh and the key (here I use ~/.ssh as the directory to place your key)
chmod 700 ~/.ssh chmod 400 ~/.ssh/guest-virgo.pem
- Log on to test AWS server (password-less)
ssh -X -i ~/.ssh/guest-virgo.pem email@example.com
Connecting via Windows (MobaXterm)
Recommend to use "Documents\MobaXterm\home\.ssh", which should exist if you have already installed the free MobaXterm.
- Create new session, click SSH, enter virgo.arcs.az.njit.edu for Remote host, guest for username.
- On advanced SSH settings tab, click Use private key, navigate to and select file guest_key.pem
- Close setup window and click the new sessions icon, which will log you in.
Startup SunCASA and sswIDL
Once the connection is setup, you will have access to SunCASA and GSFIT (included in the sswIDL installation). To not interfere with others (who share the same "guest" account), please create your own directory and work under it. For easier identification, please use the initial of your first name and your full last name such as "bchen"
[guest@ip-172-26-5-203 ~]$ mkdir bchen [guest@ip-172-26-5-203 ~]$ cd bchen
[guest@ip-172-26-5-203 ~/bchen]$ suncasa
[guest@ip-172-26-5-203 ~/bchen]$ sswidl
SunCASA Installation on Your Own Machine
We have packed a standard disk image (dmg) for installation on MacOS. It has been tested to work under Mojave (macOS v10.14). YMMV for earlier versions of macOS. Installation steps below:
- Download SunCASA disk image (SunCASA-0.7.5_Pre-release.OSX.dmg).
- If you do not have Java SE Development Kit (JDK) installed on your Mac, please download from the official site and install it before SunCASA installation. The latest version (JDK 12) was tested to work properly. Earlier versions may also work but YMMV.
- Open the disk image file (if your browser does not do so automatically).
- Drag the SunCASA application to the Applications folder of your hard disk.
- Eject the SunCASA disk image.
- Double-click the SunCASA application to run it for the first time. If the OS does not allow you to install apps from non-Apple sources, please Change the settings in "System Preferences-> Security & Privacy -> General" and "Allow applications downloaded from: Mac App store and identified developers". If the OS still reports that the app is damaged, please turn off the OS Gatekeeper for now by running command sudo spctl --master-disable in Terminal. Then double-click the SunCASA application again.
- Initialize SunCASA. To do so, run !install_suncasa from a SunCASA prompt. This step also allow you to create symbolic links to the SunCASA version and its executables (Administrator privileges are required), which will allow you to run suncasa, casaviewer, casaplotms, etc. from any terminal command line.
- Important: Make sure to turn the OS Gatekeeper back on after the installation by running sudo spctl --master-enable in Terminal.
- Optional: To update the data repository, run !update-data from the SunCASA prompt.
- Restart SunCASA by exiting the current SunCASA prompt, and run suncasa in Terminal or double-click the SunCASA application icon.
- Now SunCASA has been up and running on your Mac.
- To install SunCASA for Linux, we have a binary distribution of SunCASA which is available as a downloadable tar file. We have tested the package under Scientific Linux 6 (derived from RHEL 6) and CentOS 7 (equivalent to RHEL 7). They may work under some other Linux distributions (e.g. Ubuntu), but YMMV.
- The following libraries need to be available to run (Sun)CASA, if they do not already come with your distribution. In Redhat/CentOS, for example, use "yum install yourpackagename" to install.
- Download the packages
- Untar the package
tar -xzvf SunCASA-release-##version##.tar.gz
You do not have to have root or sudo permission to install or run SunCASA. The package is self-contained in the (untarred) directory "SunCASA-release-##version##". You can move/delete the SunCASA directory as you wish. But to use the executables, do the following:
- All executables, including suncasa are in the SunCASA-release-##version##/bin directory. Include these executables to your path for once (examples below are in bash)
cd SunCASA-release-##version##/bin PATH=`pwd`:$PATH
- Then you can initialize SunCASA with the command in bash
- Optional: To update the data repository, run !update-data from the SunCASA prompt.
- Now SunCASA has been successfully installed on your machine. Open a new Terminal and run suncasa.
Please click on the link above for details regarding installation of GSFIT. This will take you to another page.
Spectral Imaging with SunCASA
Before Starting SunCASA
You will likely be running SunCASA from a working directory that has your data on it, or where you want your output to go. Warning: SunCASA does not like a directory that contains spaces in its path. If you have done your own installation as instructed above, then there should be an executable script called suncasa in your system path. This script will set up the required environment and run the version of SunCASA that it points to.
You can open up a terminal, cd your working directory (e.g., ~/bchen/), and type
EOVSA data is handled in CASA tables system, known as a Measurement Set (MS). The actual visibility data are stored in a MAIN table that contains a number of rows, each of which is effectively a single timestamp for a single spectral window and a single baseline. Within SunCASA, you will have access to a collection of tools that allow you to explore and utilize the new radio dynamic spectroscopic imaging data from EOVSA.
Please click on the link above for detailed instructions (which will direct you to another page).
Spectral Fitting with GSFIT
GSFIT GUI Application
The GSFIT GUI application may be launched as follows
IDL> gsfit [,nthreads]
where nthreads is an optional argument that indicates the number of parallel asynchronous threads to be used when performing the fit tasks. By default, GSFIT launches with only one thread, but the user may interactively add or delete threads as needed at the run-time up to the number of CPUs available on the system (Note, if you are working on the AWS server, please use only one thread). After some delay while the interface loads, the GUI below should appear.
A detailed description of the GSFIT functionality is provided in the page linked below.
GSFITCP Batch Mode Application
GSFITCP is the command prompt counterpart of the GSFIT GUI microwave spectral fitting application. Once started, GSFITCP is designed to run in unattended mode until all fitting tasks assigned to it are completed and log on the disk in an user-defined *.log file, the content of which may be visualized using the GSFITVIEW GUI application. When run remotely on an Linux/Mac platform, the GSFITCP may be launched on a detached screen, which allows the remote user to logout without stopping the process in which GSFITCP runs.
GSFITCP is launched using the following call:
IDL> gsfitcp, taskfile, nthreads, /start
where taskfile is a path to a file in which a GSFIT task has been previously saved, as explained in the GSFIT Help page, nthreads is an optional argument indicating the number of parallel asynchronous threads to be used, and the optional keyword /start, if set, requests immediate start of the batch processing.
A detailed description of the GSFITCP functionality is provided in the page linked below.
GSFITVIEW GUI Application
The GSFITVIEW GUI application may be launched as follows
IDL> gsfitview [,gsfitmaps]
where the optional gsfitmaps argument is either the filename of an IDL *.sav file containg a GSFIT Parameter Map Cube structure produced by the GSFIT or GSFITCP applications, or an already restored such structure.
A detailed description of the GSFITVIEW functionality is provided in the page linked below.