PyData London 2024

Strategic Planning in Public Health: Linear Programming for Resource Allocation
06-15, 12:00–12:40 (Europe/London), Salisbury

The Togolese Ministry of Health distributes contraceptives to women across the country every year. The Ministry employs two different types of interventions (open days at district health clinics, and mobile clinics that travel to remote regions), implemented multiple times in a year and in different districts, to achieve an annual target of the number of women reached (i.e. coverage). However, the two types of intervention have varying costs and varying efficacy in reaching women in different districts. This makes planning and budgeting for the interventions while also achieving a desired coverage extremely challenging for the Ministry. In this talk, we will explore how this problem may be tackled using linear programming to optimize how the two interventions are implemented across districts and at multiple timepoints annually. We analyze historical data and leverage optimization models to tailor implementation of the two interventions to ensure cost-effectiveness while meeting coverage targets. We also discuss different variants of the optimization model to introduce flexibility and customization for managing resources, the assumptions involved, and their utility in improving intervention planning. Attendees will gain insight into the technical complexities of implementing linear optimization models, the challenges involved in using them for decision-making, and its potential to help efficiently allocate scarce resources. Suitable for data professionals interested in implementing data-driven solutions to improve resource allocations under specific constraints. No prior knowledge required.


In order to advance their women health care agenda, the Ministry of Health in Togo has a mission to distribute contraceptives to the local population. Every year they plan for a combination of two strategies: JPOs where they implement “open days” at district hospitals and MOBs where they travel to remote regions. The Ministry implements a combination of these two strategies in each of the 39 districts. In general designing and executing public health interventions requires meticulous planning and resource allocation. Contraceptive distribution in Togo is no different, particularly when the Ministry aims to meet an annual target of women receiving contraceptives (i.e. coverage) in a cost-effective manner. Every year, the ministry plans for a combination of two strategies. The Ministry typically determines a nationwide combination manually, and leaves up to the district administration how to implement them. These numbers are determined depending on the target set for coverage. However, finding the right combination of JPOs and MOBs to meet coverage targets is challenging, since this requires them to account for the nuanced landscape of Togo's healthcare needs as well as the varying population density and the cost of implementation in each district.
We use a linear optimization model to improve this process. Our solution is a data-driven analytical approach that allows intervention planning to be more flexible and granular: we provide recommendations for each district and for each quarter, determining precisely how many times to run JPOs or MOBs in each district annually. We also determine in which remote areas per district to implement MOBs. Our model incorporates data from past interventions, including the cost and the coverage obtained per district.

Our model uses both Python and Julia. We used Julia's JuMP library for implementing and fitting the optimization models, and Python for data analysis, data visualization, and to build the pipeline. We chose this approach to leverage Julia's advanced optimization capabilities through the JuMP library and Python's ease of deployment, data analysis and visualization capabilities. We integrate the two via the "Julia" Python library for an efficient modeling pipeline.

During this presentation, we will describe the process of designing and implementing the optimization model. We will delve into the challenges we encountered, the implementation choices we made, and the lessons we learned about implementing data-driven solutions in a low-resource government setting. Attendees will gain insights into the practical application of data science in public health, the potential for linear programming to enhance healthcare delivery in low-resource settings, and the steps involved in creating impactful data-driven solutions.


Prior Knowledge Expected

No previous knowledge expected

Carlos is a data scientist at IDInsight where he plays a key role in designing, testing, and improving various algorithms for partners.
Prior to joining IDinsight, he worked as a machine learning engineer for Gozem a ride-hailing startup based in Togo, implementing, improving and deploying machine learning models. He has also previously worked as a data scientist for the Togolese Ministry of Digital Economy, building dashboards.

Carlos holds a masters in Data Science from the Middlesex University of London and a bachelor’s in Mathematics and Computer Science at the Catholic University of Africa, Lome.

He has also co-authored a research paper studying extended category learning with Spiking Nets and Spike Timing Dependent Plasticity. Carlos is fluent in French, English and Ewe.