SAS Requirements - XMM-Newton
Software and Tools required to work with SAS
Table 1 shows the software and tools required to work with SAS 19.1. Column Version shows the versions used in the build of SAS 19.1, column Web page includes the URL to get the specific software or tool and column Comments provides specific hints or links to addtional information you should consider to work with the software or tool.
|X11||Provided by building OS||N/a||On macOS you need to install Xquartz regardless of the OS version. XQuartz v2.7.11 has been tested successfully with macOS Catalina. The new XQuartz v2.8.0 is not yet fully tested neither on macOS Catalina nor on BigSur. For the time being, please do not upgrade to this version.|
Latest version is 3.9.2.
Binaries ready to install for Linux, macOS, Windows, etc.
|Detailed description on the SAS 19.1 Python environment can be found below.|
|Perl||5.30.1||perlbrew will help you to download and install it.||Detailed description on the SAS 19.1 Perl environment can be found below|
|ds9||8.2.1 or later||SAOImage ds9 download site.||The tool xpa 2.1.20 (or later), not included with ds9, is required to work with SAS. Pleasse download it from the same download site and install it together with ds9.|
|Grace||5.1.25||The Grace web site provides only the source code.||
Installation from source code is difficult. However, both CentOS and Ubuntu provide binary packages which are easily installed.
|Heasoft||6.28||Binaries and source code available from Heasoft web site.||Details on how to build Heasoft from source code to be compatible with SAS 19.1 can be found below.|
|WCSTools||3.9.6||The WCSTools web site provides only the source code.||Easy to build from source code. Please do not install WCStools v3.9.5 because its scat tool does not work when going to download data from internet, e.g. by setting the UB1_PATH environment variable to query the USNO Catalogue.|
Some SAS tasks are Perl scripts, e.g emchain, epchain, omichain, etc. In order to run, they require that a proper Perl be installed in your system and be available through the PATH environment variable.
Before installing SAS 19.1, please install Perl 5.30.1 using the perlbrew tool. Then, before running the SAS 19.1 install.sh script, define the environment variable SAS_PERL to point to the Perl 5.30.1 binary provided by such installation.
All SAS 19.1 Perl tasks search for the perl binary using /usr/bin/env in the first line of the script (she-bang). The SAS installation script configure_install ensures that all SAS 19.1 Perl task's she-bangs use that mechanism to find in PATH, the right Perl binary.
Given that Heasoft includes also Perl tasks, please ensure that the installation of this software, either from source code or from pre-built binaries, uses the same Perl 5.30.1 used for SAS 19.1. That is accomplished by defining the PERL environment variable to point to such binary, before building or installing Heasoft.
The following Perl modules are also required:
The installation of these modules can be done using the CPAN module included with perl 5.30.1, as follows
perl -MCPAN -eshell
where perl should be the same binary used to work with SAS 19.1.
The SAS 19.1 initialisation scripts created during the installation take care of the proper initialization of the standard Perl environment variables PERL5LIB and PERLLIB.
Besides Python 3.8.2 or later, the following Python packages are required to work with SAS 19.1
All these packages can be installed by means of pip, the Python package installer, one by one or at once by means of file sas_19.1.0_python_packages.txt, which is included in the SAS 19.1 root installation directory. To perform the installation of all these packages, you can use the following command
pip install -r sas_19.1.0_python_packages.txt
Before doing it, please ensure that Python 3.8.2 (or later) is available through the PATH.
At difference with Perl, for Python it is not necessary to define a SAS_PYTHON environment variable. However, like perl, python must be available through the PATH, to be used from any SAS 19.1 Python task's she-bang.
SAS initialisation scripts created during installation take care of the proper definition of the standard Python environment variable PYTHONPATH.
Although we recommend installing the required Python packages listed earlier using pip, there are other tools like miniconda, anaconda, etc, which can be used as well to create a proper Python environment.
Although a binary installation of Heasoft is sufficient to work with SAS, if you build it from source code --e.g. because you want to compile new Xspec models-- to make such build fully compatible with SAS 19.1, please do not forget to define both, the PERL and the PYTHON environment variables, to point to the Perl 5.30.1 and the Python 3.8.2 (or later) binaries used to work with SAS 19.1.
The installation of Grace from source code on macOS can be done using different software tools. Good examples are Macports and homebrew. However, we have found that Qt Grace 0.2.6 binaries provide an excellent and easy alternative to these methods.
Once downloaded from the web site indicated in Table 1, please install the dmg package as usual on macOS. The qtgrace.app will be available as an standrad application in the /Applications folder. However, SAS is not prepared to work with it but with something named xmgrace, available from the command line. But you can create the xmgrace command line application by executing the following commands from a standard terminal:
sudo ln -s qtgrace xmgrace
To complete the installation you must add the /Applications/qtgrace.app/Contents/MacOS directory to your PATH.
Qt Grace is not an X11 application, therefore you will not get its GUI when run it remotely through ssh.