Computing setup

This course has a heavy programming component and will turn increasingly data- and compute-intensive throughout the semester.

Image may contain: Computer hardware, Computer, Computer networking, Electricity, Gas.

Access to Fox

Our reference computing environment will be the Fox high-performance computing cluster belonging to the University of Oslo. All course participants will be granted access to Fox, where about 3,000 CPU cores, compute nodes with up to 512 GByte of main memory, and a (small) rack of massively parallel GPUs are available.  To register  for Fox usage, please submit an on-line form, where you should apply for a membership in the ec30 project (Language Technology Group; LTG) until June 30, 2023.  It will usually take a day or two before account activation is complete, and you will receive status updates by email and text messages.

Once you have received confirmation of account activation on Fox, you need to connect using ssh (e.g. from the Linux command-line, or any suitable secure shell client), e.g.

 ssh fox.educloud.no

This will establish an interactive session on one of the Fox login nodes, which we can use for development, debugging, and testing.  In a nutshell, moderate computation is fair game on the interactive login nodes, where we interpret ‘moderate’ as, say, using at most a handful of cores, up to 16 gigabytes of main memory, and run-times best measured in minutes.

If you feel there is a need to familiarize yourself with working in Linux command line environment, we recommend reading this tutorial and/or taking some on-line Linux basics course. The Missing Semester of Your CS Education by MIT is another good course on mastering the command line and other basics.

Python Modules

Python 3 is  the main programming language for this course.  Once logged into Fox, there is an NLP-specific repository of the relevant Python 3 add-on modules. Most of them are "branded" with NLPL, that is, "Nordic Language Processing Laboratory".  To activate this environment, one needs to execute the following commands:

module purge
module use -a /fp/projects01/ec30/software/easybuild/modules/all/
module load nlpl-nlptools/2022.01-foss-2021a-Python-3.9.5
module load nlpl-gensim/4.2.0-foss-2021a-Python-3.9.5
module load nlpl-pytorch/1.11.0-foss-2021a-cuda-11.3.1-Python-3.9.5

We recommend you add the above lines to your personal .bashrc configuration file in your home directory.  You can check that you have a sane working environment by issuing the commands above and then running our sanity test script.  It will try to import all the necessary Python packages.  In case the test script produces some warnings or errors, send a question to our collective mailbox, or raise an issue in our UiO GitHub repository.  

List of all modules available in the NLPL Virtual Laboratory

Please do not try to install any Python modules locally to your user directory on Fox.  This may conflict (in subtle, intransparent ways) with the environment we have prepared for the course.  In other words, make sure that the ~/.local/ directory inside your home directory on Fox is empty (unless you are absolutely sure you know what you are doing).

Fox Foundations

Computations that will run for more than a few minutes, require a GPU, multiple CPUs or very large amounts of memory, must be submitted through the Fox queue management system, using the so called SLURM scripts. To learn how to deal with this system, read the Fox job system overview. We will have a quick workshop on Fox technicalities during one of the first group sessions. We also provide an example of a SLURM script, which you can use as a template.

Recommended Editors

You can either develop your code on your computers and then copy it to Fox for larger runs, or you can work with the code on Fox itself.  There is no shortage of text editors with various levels of Python support, and we will respect whatever choices you make.  Most of the course teachers are fond of Vim editor, and will be happy to assist in getting maximum productivity with it.

If you need help in working with Vim, run the vimtutor command.  An example of Vim configuration for convenient working with Python code can be found in the repository.  Simply copy this file to your home directory on Fox, if you do not yet have a file by that name already, or merge the contents of our file into yours.

Published Jan. 16, 2023 7:21 PM - Last modified Jan. 24, 2023 6:14 PM