Back to Table of Contents
Installing and running COSMOS
Using pre-compiled binaries
Compiling your own binaries
Using pre-compiled binaries
At the telescope
COSMOS is located in /usr/local/magellan/Cosmos2.
Before running any programs, you must execute the following commands:
- source /usr/local/magellan/Cosmos2/magellan-setup
- cp -r $COSMOS_HOME/Cospar $HOME
If you wish to use the IRAF routines display8 and combine8, you must execute
the following lines at the cl prompt, or put them in your login.cl file:
- task display8 = "/usr/local/magellan/Cosmos2/bin/display8.cl"
Remember to execute "source /usr/local/magellan/Cosmos2/magellan-setup" in any new windows that you open or put it in your shell startup script.
Santa Barbara Street
The COSMOS software is installed on chiaki, and should be usable from any
machine running Linux.
Before running any programs, you must do the following:
- Execute, and copy into your shell startup file (e.g. cshdef or .cshrc) the following commands so that they will be defined in each window you open:
setenv COSMOS_HOME /data1/chiaki/gwalth/Cosmos/Cosmos2
source $COSMOS_HOME/cosmos2-setup
setenv COSMOS_PAR_DIR /home/joe-user/whatever
If you are running a 64-bit machine you will want to use the following COSMOS_HOME directory instead:
setenv COSMOS_HOME /data1/chiaki/gwalth/Cosmos/Cosmos2_64
- Execute the following command to copy the Cospar directory to where you want it, containing the program parameter files:
cp -r $COSMOS_HOME/Cospar /home/joe-user/whatever
- If you have trouble with the Perl libraries you can also use chiaki for that as well:
setenv PERLLIB /data1/chiaki/gwalth/Cosmos/perl/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi
If you are running a 64-bit machine you will want to use the following PERLLIB setup instead:
setenv PERLLIB /data1/chiaki/gwalth/Cosmos/perl_64/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi
- If you wish to use the IRAF routine display8, you must execute the following lines at the cl prompt, or put them in your login.cl file:
task display8 = "/data1/chiaki/gwalth/Cosmos/Cosmos2/bin/display8.cl"
The documentation is available locally at www.ociw.edu/Code/cosmos
Compiling your own binaries
Here you can find the latest release at www.ociw.edu/Code/cosmos/source.
COSMOS is known to work with the following:
Architecture | Operating System
|
---|
x86 | Redhat 8, 9; Fedora Core 1, 4, 5; Mac OS X 10.4
|
x86_64 | Fedora Core 8
|
PowerPC (G4, G5) | Mac OS X 10.3, 10.4
|
COSMOS should work on most other Linux systems, and may work on any UNIX variant.
COSMOS at this time does support FFTW3. There is a significant slow down in the way the code is runs with FFTW3. It is recommended to use the most recent version of FFTW2.
Dependencies
Besides the usual stuff, you will need:
If you wish to use the GUI programs setcosdir, defineobs, and viewspectra, you
will also need the following Perl modules:
If you wish to use ldss3-pattern you will need the following library:
Installation
- Retrieve the COSMOS tarfile.
- On your system, create a directory into which the COSMOS system will be installed.
- define the environment variable COSMOS_HOME to be that directory, e.g.
setenv COSMOS_HOME "/home/joe_user/my-cosmos2-directory"
- move the tarfile to this directory
- extract the tarfile:
tar -xzvf cosmosYYYY.tar.gz
- execute cd source
- You are now ready to build the executable files, but first make sure that the library files (and possibly their associated include files) that are needed are in the expected locations, which are specified in the Makefile. The libraries in question are:
- libcpgplot
- libcfitsio
- libpgplot
- libX11
If they are not, you must do one of the following:
- copy the files into
$COSMOS_HOME/lib
- create symbolic links to the files in
$COSMOS_HOME/lib
, (and $COSMOS_HOME/include
)
- edit the Makefile definitions of PGLIB, FITSLIB, and XLIB, (and PGINC, FITSINC, XINC)
- specify the locations on the make command line, as seen below,
Now, you are ready to execute the make command
make -f Makefile.system [PGLIB=pgplot-dir XLIB=Xll-dir FITSLIB=fits-dir
PGINC=pgplot.h-dir XINC=X11.h-dir FITSINC=fits.h-dir]
where system is either "Mac" or "linux", and the options in brackets are only
needed if the above mentioned library and header files are not in their
expected locations. With a little luck, you will get no error messages, and at
the end you will have a completely installed system. The most likely errors are
due to a failure to find all the library and header files. Check their
locations.
To compile ldss3-pattern:
- Make sure that the library files and their associated include files are in the expected locations, which are specified in the Makefile. The libraries in question are:
- libfftw
- librfftw
If they are not, you must do one of the following:
- copy the files into
$COSMOS_HOME/lib
- create symbolic links to the files in
$COSMOS_HOME/lib
, (and $COSMOS_HOME/include
)
- edit the Makefile definitions of FITSLIB, and FFTWLIB, (and FITSINC, FFTWINC)
- specify the locations on the make command line, as seen below,
Now you are ready to execute the make command for ldss3-pattern
make -f Makefile-ldss3.system [FITSLIB=fits-dir FFTWLIB=fftw-dir
FITSINC=fits.h-dir FFTWINC=fftw.h-dir]
Some final tidying:
- execute, and copy into your shell startup file (e.g. cshdef, .cshrc) the following commands so that they will be defined in each window you open:
setenv COSMOS_HOME "/home/joe-user/my-cosmos2-directory"
source $COSMOS_HOME/cosmos2-setup
setenv COSMOS_PAR_DIR "/home/joe-user/my-Cospar-directory"
where my-cosmos2-directory and my-cospar-directory are the locations you have chosen for the cosmos2 software and the Cospar files.
- Move the Cospar directory to the location you have chosen, as described above.
- If you wish to use the IRAF routine display8, you must execute the following lines at the cl prompt, or put them in your login.cl file. Note that you must specify the full path to the cosmos directory, since IRAF forgets your environment variables, such as COSMOS_HOME
task display8 = "/home/joe_user/my-cosmos-directory/bin/display8.cl"
The HTML documentation will be available on your own computer at $COSMOS_HOME/docs/COSMOS.html
.
Need some help?
If you have trouble with installing or running COSMOS, please
- Make sure that you have the latest version
- Make sure that you have carefully read all of the documentation
- If things still don't work, you can contact cosmos[at]ociw.edu for assistance.
Next: COSMOS Cookbook
Back to Table of Contents