Warwick SCRTP

Basics

  • Register for an account here.
  • Documentation is here. Use your Warwick id/pass to get in.
  • Methods to connect are under SCTRP Linux/Remote access. If you don’t know what ssh is, the web browser access is probably simplest.
  • Log into my machines vega1.astro.warwick.ac.uk or betapic.astro.warwick.ac.uk (do not use the shared gateway machine godzilla).
  • The terminal is the main way to do things on the machines, open one by double clicking on the icon on the desktop.
  • There is some information on the Linux command line (terminal) in the Docs under General information.

Loading modules

When logging in to SCRTP machines, run the command below in a terminal to get access to python and some necessary modules. This will allow you to run a jupyter notebook too.

module load GCC/11.3.0 Python/3.10.4 IPython/8.5.0 FFTW/3.3.10 OpenMPI/4.1.4 astropy/5.1.1 matplotlib/3.5.2 h5py/3.7.0 CMake/3.24.3

If you then type module save, you can restore the configuration next time with module restore (rather than pasting the whole command in each time).

Python

If you need python modules that don’t exist in (e.g. you get import errors), you can install these with something like pip install --user rebound. This puts them in a hidden folder in your home space. You will need to have restored the modules above for this to work.

Having loaded the modules, open a jupyter notebook by typing jupyter notebook. This will open a browser window with the jupyter file browser, use this to find and then run your notebook.

Running long jobs

You can run code that will take a while by using screen. Typing screen in a terminal will open a new terminal session in that window (you will need to type module restore again). Here you can start a piece of code and then exit with ctrl-a d. The terminal is still running but you can leave (e.g. close the brower or terminal window) and come back later with screen -r.

Mac setup

My list of software to get a new mac up to speed. Latest was el Capitan.

  • Run software update
  • Sign into iCloud, turn everything but Notes off
  • Check shell is zsh in System Preferences (apparently default?)
  • Various finder preferences, e.g. filename extensions
  • Turn on FileVault, Firewall
  • Chrome
  • Office
  • Xcode (also xcode-select --install)
  • Slack
  • x2go
  • MacTex and BibDesk (use TeX Live Utility to do updates and check paper size )
  • XQuartz
  • homebrew (this involved cloning homebrew-core on a different machine with institutional internet and copying it into place)
  • web server, homebrew httpd, homebrew php, mysql
    • copy tables using mysqldump, mysql -uuser -ppass -N -e “show databases like ‘%’;” |grep -v -F mysql |grep -v -F _schema|grep -v -F sys |xargs mysqldump -uuser -ppass –databases > alldb.sql, and read back in with –force option if version related errors.
  • Sequel Pro (buggy, latest test build seems fine)
  • iObserve
  • Sublime Text
  • Topcat and the stilts script
  • cdsclient (had to compile and place wwwget to /usr/local/bin by hand)
  • ads2bibdesk (and ads)
    • comment line ~287 in python script to use bibcodes as cite key
    • service doesn’t work, but terminal OK
  • (py)multinest
    • may need to do: export FCFLAGS="-w -fallow-argument-mismatch -O2" and export FFLAGS="-w -fallow-argument-mismatch -O2" for make to work
  • galario
  • DS9

Installing galario

Steps to install galario on SCRTP and Mac.

  • For SCRTP import modules, e.g. module load GCC/8.3.0 OpenMPI/3.1.4 Python/3.7.4 FFTW/3.3.8 CMake/3.15.3 IPython/7.9.0-Python-3.7.4
  • For Mac install these with homebrew, and probably need to specify homebrew gcc/g++ when calling cmake.
  • Follow instructions here, including python binding
  • Example for Mac: cmake -DCMAKE_C_COMPILER=/usr/local/bin/gcc-11 -DCMAKE_CXX_COMPILER=/usr/local/bin/g++-11 -DPython_ADDITIONAL_VERSIONS=3.9 ..
  • Find python site-packages, create galario directory, and copy contents of galario/build/python/galario (single, double, __init__.py) into it.
  • For example; cp -r python/galario/* ~/.local/lib/python3.7/site-packages/galario/

To use galario with emcee, set the number of galario threads to 1 with galario.double.threads(num=1). It won’t work otherwise.