Python Programming for HPC

Python is probably the most versatile language in existence. However one of its most useful features is its ability to tie things together and automate the execution of other programs.

This tutorial focuses on using Python in high-performance computing environments. We’ll start with the basics and cover everything you need to get started. Some elements of writing performance-oriented code will be covered, but it is not the main focus. There is no prerequisite knowledge for this tutorial, although having some prior experience with the command-line or a compute cluster will be very helpful.

At the end of this lesson, you will know how to:

Python is a general-purpose high-level programming language. For scientific computing Python offers important advantages over other programming languages. This lesson will offer the basic instruction to start creating scripts and programs in Python in particular programs that involve numerical calculations and generation of plots.

Prerequisites

This lesson assumes that you know how to access a computer cluster. You should be confortable with at least one text editor like emacs, vi and the Linux Command Line environment.

Setup

If you want to use your own computer it is fine. You will want to have Python 3 and your favorite Python editor preinstalled and ready to go. If you don’t know where to get things or what to install, just install one of the options in the Setup episode below.

The files used in this lesson can be downloaded from the 2019 Data Repository:

$ git clone https://github.com/WVUHPC/2019-Data-HandsOn

Schedule

Setup Download files required for the lesson
Day 1 09:00 1. Introduction to Python Programming How Python in used in Scientific Computing?
10:00 2. Basic syntax Where do I start?
13:00 3. Lunch Break Break
14:00 4. The Python Standard Library What is the Standard Library and which are the main modules for scientific computing
16:00 Finish
Day 2 09:00 5. Numpy Key question (FIXME)
10:00 6. Matplotlib Key question (FIXME)
11:00 7. Scipy Key question (FIXME)
13:00 8. Lunch Break Break
14:00 9. Cython: Accelerate Python Execution What is Cython and its relation with Python?
15:00 10. Pandas Key question (FIXME)
16:00 Finish

The actual schedule may vary slightly depending on the topics and exercises chosen by the instructor.