We are an informal group of Python users in the Centre of Atmospheric Science, University of Manchester. We plan on meeting roughly every two weeks to discuss Python-related problems, and learn some new Python along the way.
The next meeting will be on Friday 6th May at 12:30pm in Room 1.10. Biscuits will be provided. Bring your own lunch.
In general meetings will take the following format:
We start with a brief informal discussion (~20 mins) session where people can ask about any Python-related question they like. Maybe you’ve heard of some cool new Python feature or Python-news. People may also bring bits of Python code they are having trouble getting to work, and we can collectively try and find solutions. There is not set theme of discussion.
The remainder of the meeting we will focus on a pre-arranged Python topic. About a week before the meeting I’ll send out a task or bit of code for us all to work through (It will not be a massive task to complete! Maybe half an hour if things go smoothly…) Then, in the meeting we will go through a solution to the problem, and we can talk about any problems we ran into, and how we might extend it to our own work. Note: Anyone can volunteer to lead this session or set the task!
The meeting should last no more than an hour roughly. You are welcome to come to either half, both, or neither.
We decided that the meetings will not be a step-by-step guide to learning Python from scratch. There are lots of good resources and courses out there on the internet that can do that sort of thing better, so you are encouraged to have a look at those. Python is said to be an intuitive language to learn, especially if you already have some programming knowledge, so hopefully you’ll pick it up quickly!
Python for the Scientific Researcher.
These are a series of courses covering NumPy, matplotlib, cartopy, and iris. Developed by the Met Office, they can be read as static pages, but are best experienced by downloading the IPython notebook files and running through them interactively with the
ipython notebook viewer on your own PC. (You may need to install ipython first).
Python for Earth Scientists.
Some good, concise notes about using Python for geosciences/atmos sciences. Includes Numpy, Matplotlib, etc.
Basemap is a standard extension of matplotlib for plotting 2D data over outline maps. It has a large library of maps and projections and is fairly straightforward to use.
The alternative to Basemap is Cartopy. It requires separate installation on top of matplotlib (fairly painless), but is arguably more powerful and feature-rich.
Introduction to Numerical Computing with Python
Internal course run by research IT. Requires UoM login to book.
Organised by ARCHER/PRACE. The date is yet to be confirmed but will be held in Liverpool.
More permanent links and resources. Documentation and guides to Python, NumPy, matplotlib etc.
The IPython notebook is a useful tool to interactively play with Python and Matplotlib, rendering the output instantly in your browser. You need to have Ipython installed on your PC. Then you can start it from the terminal with:
The Matplotlib gallery
Sometimes the best way to learn matplotlib is to browse the sample gallery of plots, and then adapt a script to your own needs. There are all kinds of plot types available. The documentation is also well written.
NumPy is one of the main add-on modules for Python used in scientific computing. It is designed to efficiently arrange and process data in arrays or matrices. (Python’s built-in array functionality is somewhat limited without NumPy.). For Matlab converts, they even have a site dedicated to switching over to the light side: MATLAB vs NumPy differences. NumPy is intended to mirror the functionality of languages like Matlab, IDL, etc.
SciPy is a Python module that contains a range of scientific functions. If Fourier transforms, linear algebra, statistaical analysis, signal processing, image processing, etc., is your thing, you will probably find a function for it in SciPy. It covers most of the functionality of the R programming language, as well as the expensive add-on packages for Matlab.
Links to useful bits of python go here: