next up previous
Next: Getting and Installing Integral Up: OSA through Docker Previous: recommended method

Subsections

Step-by-step usage

Downloading the OSA docker image

Download the Docker image from the public Docker Hub to which ISDC has uploaded the software. (This requires 2.6 Gb of disk space and in Internet connection.)

From the Terminal command line type:

(Note that you can also specify a version with docker pull integralsw/osa:11.1, where the number after the colon, here 11.1, is a tag to the version. There are also 11.0 and 10.2 docker images if you want to download those versions. Omitting the tag will result in downloading the latest version, which is the recommended way.

Docker images will be stored in a system directory. Images can be listed from the command line with the instruction:

(see documentation for details, e.g., https://docs.docker.com/engine/reference/commandline/images/)

The command:

will remove an image.

Defining the arguments and options

Any OSA command can be executed in the docker container after some settings.

The container acts as a separate OS in which the OSA initialization is performed internally with the script ``/init.sh''. However, we have to provide through our local OS input data and a place to write the results. This can be done in the way explained below.

Any OSA command inside the docker image is run from the command line as:

Let's first create temporary directories to mount the home and pfiles to be visible within the docker image. This will avoid ``polluting'' our working directory with unnecessary outputs ($$ is a variable that stores the shell's process ID number2):

These directories will be identified and mounted using the docker options

It is necessary to specify the user name in the docker image to be the same as in the native OS, which is done with the options:

The the graphical interface options are defined as:

Uning Docker,it is easy relax the requirement to use an OSA compliant directory, as described in https://www.isdc.unige.ch/integral/download/osa/doc/11.1/osa_um_intro/index.html. We can run the software somewhere and keep in separated places the ic_tree and the archive. Following the instructions in Section [*], we can download the ic_tree in a folder which we can refer to with the shell variable CURRENT_IC. Following Section [*], we can store the archive in a place referred to with the shell variable REP_BASE_PROD These directories will contain the folders ic,idx (CURRENT_IC) and scw,aux (REP_BASE_PROD). We should can mount this directory with the options:

The output data will be contained in the working dir.

In conclusion, these are the arguments and options we need to run OSA within the docker.

In OS-X (for a graphical interface, remember to issue xhost + $ip in your shell before running OSA) and change the first line with -e DISPLAY=$ip:0.

Running OSA Commands

We are now ready to work on the <command> to run OSA tasks. Since we need to define some environment variables, it is better to run a shell that will 1) define variables, 2) initialize OSA, and 3) cd into the working directory.

Our command will then be:

Catalogs are shipped with the docker image. However, it is possible to use custom catalogs. What is needed is to place them in a folder mounted in the docker image.

We suggest to place the catalogs in the standard locations in your local file

and

And use them in the call within docker as:

We are ready to run og_create program to build our OSA observation group. We use IBIS as a example and assume that we have stored our list of science windows in the file list_scw.txt.

The OSA command is

However, we have to prepend all the necessary arguments for docker to run properly.

This will create a directory obs/my_og, with the observation group for OSA. It is now possible to run ibis_science_analysis via the command:

The graphical interface opens and you can run the ibis_science_analysis as explained in the relative the user manual (in OS-X, remember to issue xhost+$ip in the shell before running the commands and set the DISPLAY variable accordingly). With these commands, we moved into our observation group within the docker container to run ibis_science_analysis. Results will be locally stored in $PWD/obs/my_og.

To reduce data from other instruments, you should change the call to og_create appropriately and then call jemx_science_analysis, spi_science_analysis,or omc_science_analysis.


next up previous
Next: Getting and Installing Integral Up: OSA through Docker Previous: recommended method
inthelp@sciops.esa.int