UCT researchers build better research software through collaborative Python workshop

28 Jul 2026
collaborative Python workshop 2026
28 Jul 2026

Researchers from across UCT participated in the Practical Techniques for Improving Python Code in Research workshop, held at the University of the Western Cape (UWC) from 7 to 9 July 2026.

UCT participants represented the Computational Biology Division (CBIO), the Division of Biomedical Engineering, Astronomy, the Neuroscience Institute and the African Climate and Development Initiative (ACDI). The range of disciplines represented demonstrated how widely software is now used to collect, process, analyse and interpret research data across the university.

The workshop was organised through a collaboration between the UCT eResearch Centre, Research Software and Systems Engineering Africa (RSSE Africa), and the South African National Bioinformatics Institute at UWC. It was supported through the Erasmus+ programme and facilitated by Professor Colin C. Venters from the University of Limerick and CERN, and Professor Birgit Penzenstadler from Chalmers University of Technology and the University of Gothenburg.

Learning by improving imperfect code

Much of the practical work centred on the example Python project used in the Carpentries Incubator’s Building Better Research Software lesson.

The lesson introduces participants to a fictional research software project that does not follow established good practices and has little documentation. Learners are asked to imagine that they have inherited the software from a colleague who has left their research group. They must first understand and run the unfamiliar code before gradually improving it.

This provided workshop participants with a shared codebase through which to investigate common research software problems. Rather than discussing quality and maintainability only in abstract terms, participants could examine how these issues appeared in functioning Python code and compare different approaches to addressing them.

Over the three days, they worked through practical techniques for assessing code, identifying maintainability problems and restructuring software. The workshop introduced principles associated with Better Research Software and SOLID software design, as well as static-analysis tools, refactoring techniques and the critical use of AI coding assistants.

Working on the same project also created space for participants from different research fields to solve problems together. Although their disciplinary contexts differed, many of the underlying software challenges were recognisable across the group.

Beyond code that simply works

Research code is often developed incrementally to answer an immediate question. A short script may grow into an analysis pipeline, a model or a tool shared among members of a research group. Code that initially produces the required result may become increasingly difficult to understand, test, modify or reproduce.

The workshop encouraged participants to look beyond whether software runs successfully and to consider the characteristics that make it usable over time. These include clear and readable code, an understandable project structure, documented dependencies, appropriate testing and sufficient documentation for another person to work with the software.

For UCT researchers, these practices have relevance beyond the development of standalone software products. They can also improve the transparency and continuity of computational analyses, support collaboration within research teams and reduce the risk that important research processes become dependent on undocumented code understood by only one person.

Using AI coding tools critically

The workshop also considered how artificial intelligence is changing the way researchers develop software.

AI coding assistants can generate, explain and restructure code, but their outputs still require informed human evaluation. Generated code may run while containing inappropriate assumptions, unnecessary complexity or errors that are difficult to detect without understanding the underlying software and research context.

Participants therefore explored AI-assisted coding alongside established software-engineering practices. The emphasis was on using these tools critically and retaining responsibility for checking whether proposed changes were correct, understandable and appropriate for the intended research purpose.

Extending the workshop’s learning

The workshop also led to the development of RQ2Concept: Research Question to Data Model and Conceptual Code, a practical workflow template published openly on Zenodo.

The template supports researchers in breaking a research question into subquestions, identifying the data needed to answer them, modelling those data, and considering the transformations required to produce the intended research outputs. It provides one way of connecting research design with the conceptual structure of the software or workflow that will support it.

Strengthening research software practice at UCT

The workshop contributes to the UCT eResearch Centre’s work to strengthen research software practice and support the people who develop and maintain software as part of research.

The participation of researchers from CBIO, Biomedical Engineering, Astronomy, the Neuroscience Institute and ACDI illustrates that research software is not confined to a single discipline or technical community. Researchers across the university face related questions about software quality, reproducibility, documentation, reuse and long-term maintenance.

Creating opportunities for researchers to work through these challenges together can strengthen individual practice while also helping to develop a more connected research software community at UCT.