What is the minimum number of temporary workers you need to hire to absorb your weekly workload while ensuring employee retention?
Find in the link below a short animated video to explain the concept behind this solution:
In this Article, we will build a linear optimisation to calculate the number of workers needed to ensure the proper resource allocation while reducing costs.
In this repository, you will find all the code used to explain the concepts presented in the article.
Linear Optimization Examples.ipynb- Jupyter notebook with step-by-step analysisworkforce_planning.py- Standalone Python script
This project uses uv for dependency management.
# Install dependencies
uv sync
# Run the Python script
uv run python workforce_planning.py
# Or launch Jupyter notebook
uv run jupyter notebook- pandas
- pulp
- matplotlib
- jupyter
- The full write-up, with the reasoning behind the code: Optimize Workforce Planning using Linear Programming with Python
- The video: Optimize Workforce Planning with Python (Source Code)
- Test what you learned: the Supply Science App has the business optimisation quizzes, free and in the browser.
- 100+ case studies with their source code: samirsaci.com
Samir Saci, supply chain engineer and data scientist with ten years in operations across Asia and Europe. Founder of LogiGreen, creator of Supply Science. For consulting on analytics and sustainable supply chain transformation: LogiGreen. More about me: samirsaci.com/about · LinkedIn
