Python training equips African scientists with essential programming skills

The benefits of scientific computing in the daily routine tasks and undertakings of climate scientists at all levels cannot be over-emphasized. Scientific computing, despite its myriad of usefulness, has been identified to be a critical limiting factor to early career researchers and climate scientists’ research in Africa.

To bridge this gap, there is the need for concerted efforts at advancing the learning of scientific computing and its application in day-to-day activities. Python has become the defacto-standard for data analysis and research, enabling and facilitating work not possible or difficult with existing tools (for example spreadsheets).

African SWIFT and FCFA held a virtual Python training programme to build critical skills for African climate scientists.

In 2018, GCRF African SWIFT held its first Python training in collaboration with Development in Africa with Radio Astronomy (DARA) to introduce the Python programming language to researchers in atmospheric science and astronomy in Africa. Following the success of the initial training, in collaboration with Future Climate for Africa (FCFA), African SWIFT held a one-week Python workshop from 7-12 June 2021.

The second cohort included researchers in atmospheric science and meteorology, and forecasters at operational weather centres based in Africa with a keen interest in developing their data analysis skills. The virtual workshop was a theoretical and practical training targeted at equipping participants with relevant Python programming tools which will help them to analyse climate data and recreate figures suitable for international peer-reviewed journals as well as integrate the Python programming language into workflows at national meteorological operational and research centres.

The course sought to introduce participants to (i) Python modules and packages of meteorological relevance, (ii) manipulation of climate datasets of various formats using specific Python modules and (iii) visualization of climate datasets with Python. Experienced Python programmers from Kwame Nkrumah University of Science and Technology (Kumasi, Ghana), Ghana Meteorological Agency (GMet, Accra, Ghana) and the University of Leeds (UK) facilitated the week-long course. One beautiful thing worth mentioning is that the two female ECRs who were part of the four member facilitation team were trained in the first cohort, marking the success and impact of the training program.

Training targets atmospheric and climate scientists

To ensure the targeted audience were reached for this training after a call for application was sent out, applicants’ CVs and statement of purpose were reviewed. The participants were expected to have a basic knowledge in Python.

Figure 1: Scientists from operational centres and research institutions across Africa participate in the FCFA-SWIFT virtual Python course in June 2021.

A total of 38 participants from various climate-related sectors across Africa were engaged in the week-long course, a significant increase compared to the first cohort which had 20 participants. This number, although marginal, is a great step to promoting the culture of effective scientific programming and application within the sub-region, as the participants were drawn from both academic and professional/corporate fields. This is a move to allow for sustainability of the course and its continuity, and then create further learning opportunities for the atmospheric and climate science community in Africa.

Packages that participants were taken through included:

  • Working with ascii data using Numpy, Matplotlib and Cartopy
  • Handling Tabular data with Pandas and Seaborn
  • Working with NetCDF files using Xarray, Cartopy and Metpy
  • Using Xarray and Xclim for climate analysis

Evaluation

At the end of the course, participants provided feedback through a survey. The feedback was generally positive, with most participants showing excitement at the opportunity to learn Python and its application in atmospheric science. Participants again acknowledged the quality of the course content and facilitators. Below is the summary of their feedback in a graphical form.

Figure 2: Participants share positive feedback in post-training survey and evaluation.

The way forward

Overall, the 2021 FCFA-SWIFT Python course was successful and the objectives of the training were achieved. The training has empowered participants as Python ambassadors within the African climate science community. The facilitators look forward to expanding the training across Africa, reaching more early career researchers in future cohorts. A Slack channel was also set up at the end of the course for continuous engagement with the participants.

Authors & course facilitators

  • Dr. Jeffrey N. A. Aryee, Department of Physics, KNUST (Kumasi, Ghana)
  • Miss. Maureen A. Ahiataku, Hydrometeorological Unit, Ghana Meteorological Agency (Accra, Ghana)
  • Miss. Marian A. Osei, Department of Physics, KNUST (Kumasi, Ghana)
  • Dr. Leif Denby, School of Earth and Environment, University of Leeds (UK)