End-to-end data platform for manufacturing performance monitoring, root cause analysis, and operational decision support
This project implements a structured, cross-functional performance analysis framework for industrial packaging workshops.
Key goals:
- Cross-workshop performance benchmarking
- Line and equipment reliability monitoring
- Operator and team performance assessment
- Root cause analysis of production downtime
- Continuous improvement decision support
It consolidates raw operational shopfloor data into a centralized analytical model for industrial steering.
Coming soon...
This project showcases:
- End-to-end data pipeline design (raw β DW β BI)
- Industrial data modeling (MES-inspired)
- KPI engineering (OEE, downtime, quality)
- Analytical thinking for root cause analysis
- Scalable architecture design (dbt, Airflow-ready)
π Designed as a portfolio-grade industrial data platform
Food manufacturing β Dairy packaging operations.
- Oval lines, Camembert lines, Portion lines
- Stacker / Destacker
- Wrapping machines
- Case packers
- Conveyor systems
- Morning / Evening / Night
- Weekend (Saturday / Sunday)
- 80 units/min β 4,800 units/hour (ideal operation)
- System identifies the affected organ and component
- Operator performs corrective action
- Event recorded on shift sheet
- Operator shift sheets, hourly granularity
- Production counters, actual units packaged
- Downtime events, component-level and manual notes
- Planned operations, e.g., breaks, cleaning, warm-up
Note: All repository data are synthetic mock data, reflecting realistic operational behavior without exposing sensitive information.
Downtime (minutes) = (Theoretical production β Actual production) / Units per minute
Loss categories:
- Technical stoppages (mechanical, electrical, process)
- Organizational interruptions (supply, changeovers)
- Planned operations (breaks, cleaning, warm-up)
- Maintenance interventions
- All workshops, lines, machines, and components
- All operational roles (operators, team leads, supervisors)
- Focus on systemic performance, not individual evaluation
- Operational understanding
- Data extraction & structuring
- Event normalization & taxonomy standardization
- Multi-line/workshop modeling
- Downtime quantification & root cause analysis
- Cross-sectional comparisons (lines, teams, periods)
- KPI & dashboard construction
- Full industrial process representation
- Links factories, workshops, lines, shifts, production, events
- Ensures traceability and auditability
- Derived, aggregated, and simplified
- BI-ready (Power BI, Tableau)
- Abstracts complexity for operational teams
Dimensions:
dim_machineβ machine metadatadim_timeβ shift, hour, day, week, monthdim_teamβ operators & shiftsdim_organe_elementβ components & subcomponentsdim_eventβ standardized downtime classification
Fact Tables:
fact_hourly_performanceβ hourly metricsfact_production_eventsβ downtime & root causes
Data Flow:
Raw Data (CSV / Excel)
β
Python ETL (Clean, Validate, Model)
β
Processed / Curated Parquet
β
PostgreSQL Staging β Dimensions β Facts
β
SQL Analytics Layer (Aggregations, KPIs)
β
BI Tools (Power BI / Looker / Tableau)
flowchart LR
subgraph "Sources"
A[Shopfloor Systems]
B[IoT Sensors]
C[ERP / MES]
end
subgraph "Bronze Layer - Raw Data"
D[Raw Data Lake]
end
subgraph "Silver Layer - Cleaned and Transformed"
E[Data Cleaning]
F[Data Transformation]
end
subgraph "Gold Layer - Business Ready"
G[Data Warehouse]
H[SQL KPIs]
end
subgraph "Consumption"
I[BI Dashboards]
J[Operational Decisions]
end
A --> D
B --> D
C --> D
D --> E
E --> F
F --> G
G --> H
H --> I
I --> J
...
- Separation of OPS and DW layers β ensures scalability and clarity
- Star schema modeling β optimized for BI performance
- Event-level granularity β enables root cause analysis
- Hourly aggregation β balances precision and performance
- Synthetic data simulation β allows safe experimentation
π These choices reflect real-world industrial data constraints
| Layer | Tools |
|---|---|
| Ingestion & ETL | Python, Pandas |
| Storage & Processing | PostgreSQL, Parquet |
| Analysis & Exploration | Jupyter, NumPy |
| Visualization & BI | Power BI, SQL |
| DevOps & Versioning | Git, GitHub, GitHub Actions |
- Reliability (%) = Actual Production / Theoretical Production
- Utilization Rate (%) = (Actual Operating Time / Scheduled Time) Γ 100
- Throughput (units/hour) = Total units produced / Production hours
- Downtime (%) = Total downtime minutes / Total available minutes Γ 100
- Planned vs Unplanned Downtime (%) = Planned / Unplanned downtime ratio
- Mean Time Between Failures (MTBF, min) = Operating time / Number of failures
- Mean Time to Repair (MTTR, min) = Downtime / Number of failures
- Defect Rate (%) = Number of defective units / Total units produced Γ 100
- First Pass Yield (FPY, %) = Units meeting quality standard on first pass / Total units
- Operator Efficiency (%) = Actual output / Expected output per operator
- Shift Performance (%) = Sum of line outputs per shift / Theoretical shift output
- Explained Loss Rate (%) = Explained downtime / Total downtime
- Top 5 Root Causes (%) = Contribution of main downtime categories to total loss
- Pareto Analysis Coverage (%) = % of total downtime captured by top causes
data/β raw, processed, curatednotebooks/β analysis & modelingsrc/β Python modules (ingestion, modeling, utils)sql/β schemas, tables, queriesdocs/β architecture, data model, KPI definitionsdashboards/β Power BI files
The Power BI dashboard follows a standard industrial monitoring structure:
Interactive overview of industrial performance:
- KPI monitoring (OEE, downtime, reliability)
- Pareto analysis (80/20)
- Machine impact visualization
π Designed for real-time operational decision-making
dashboards/
βββ powerbi/
βββ sales_performance.pbix
βββ screenshots/
-
Initialize SQL tables
-
Load staging
-
Build dimensions
-
Populate fact tables
git clone git@github.com:mounkaila-issoufou/industrial-downtime-analytics.git
cd industrial-downtime-analytics```text
python -m venv .venvActivate the environment:
Windows
.\.venv\Scripts\activatemacOS / Linux
source .venv/bin/activatepython -m pip install --upgrade pip
python -m pip install -e .Editable mode (-e) allows local development and CLI usage.
If you add or modify dependencies in pyproject.toml, regenerate the locked requirements.txt file with:
pip install pip-tools
pip-compile pyproject.toml -o requirements.txtThis will:
-
Resolve all transitive dependencies
-
Lock exact versions
-
Keep requirements.txt fully synchronized with pyproject.toml
Before running the pipeline for the first time:
industrial-downtime initThis command:
-
Creates schemas (stg, ops, dw)
-
Creates all staging, operational, and data warehouse tables
- Prepares the full database structure
To truncate all data (without dropping tables):
industrial-downtime resetThis clears all data layers while keeping the database structure intact.
To execute the full end-to-end pipeline:
industrial-downtime runor
python -m industrial_downtime.cli run-
The pipeline performs:
-
Mock industrial data generation
-
Staging layer load
-
Operational layer transformation
-
Data warehouse population
For a complete refresh:
industrial-downtime full-refreshinit β Create schemas & tables
reset β Truncate data layers
run β Execute full DML pipeline
full-refresh β Reset + RunWe use pre-commit to ensure code quality and consistent formatting before committing. It automatically runs tools like black (code formatter) and ruff (linter) on your modified files.
pip install pre-commitCreate a .pre-commit-config.yaml at the root of your project:
repos:
- repo: https://github.com/psf/black
rev: 24.0
hooks:
- id: black
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.326
hooks:
- id: ruffpre-commit installThis installs the Git hook. From now on, every git commit will automatically check your code.
Simply work as usual and commit your changes:
git add .
git commit -m "feat: add new feature"Pre-commit will check and format modified files automatically.
If issues are found, fix them and commit again.
To apply hooks to all files in the project (useful when first setting up):
pre-commit run --all-files
Consolidated performance overview
Root cause analysis of downtime
Cross-line / workshop comparison
Improvement prioritization
Based on modeled industrial scenarios:
- 3% OEE improvement β +X units/day
- 10 min MTTR reduction β +Y hours/month recovered
- Top 3 root causes removal β -Z% downtime
Example 1: If Line A underperforms 3 consecutive shifts β trigger maintenance audit.
Example 2: If MTBF < threshold β preventive maintenance scheduling.
Example 3: If weekend performance < weekday performance β workforce adjustment analysis.
-
Architecture β docs/architecture_overview.md
-
Star schema β docs/data_model.md
-
Data dictionary β docs/data_dictionary.md
-
KPI definitions β docs/kpi_definitions.md
-
Assumptions & limits β docs/assumptions_and_limits.md
-
Manual data entry, approximate durations
-
Hourly granularity
-
Micro-stops not always captured
This project structure is inspired by real dairy packaging operations, including shift-based production monitoring, TRS calculation, and component-level downtime tracking.
This project is evolving from a data warehouse prototype into a production-ready industrial data platform, designed to integrate with real-world systems such as MES and ERP.
Build a scalable and modular data architecture capable of:
- Integrating industrial data sources (MES, IoT, ERP)
- Supporting both batch and streaming ingestion
- Ensuring data quality, traceability, and reprocessing
- Delivering reliable KPIs (OEE, downtime, quality)
Sources (MES / ERP / IoT)
β
Ingestion (Airflow / Kafka)
β
Data Lake (S3 / MinIO)
β
Transformation (dbt)
β
Data Warehouse (PostgreSQL / Snowflake)
β
BI / APIs (Power BI / FastAPI)
| Layer | Technology | Status |
|---|---|---|
| Ingestion (Batch) | Apache Airflow | β³ Planned |
| Ingestion (Stream) | Apache Kafka | π Optional |
| Storage | MinIO (S3-compatible Data Lake) | β³ Planned |
| Transformation | dbt | π§ In Progress |
| Data Warehouse | PostgreSQL | β Current |
| API Layer | FastAPI | π Optional |
| BI / Analytics | Power BI | β Current |
| Containerization | Docker | β³ Planned |
| Data Quality | dbt tests / Great Expectations | β³ Planned |
| Monitoring | Prometheus + Grafana | π Optional |
- Migrate SQL pipeline to dbt
- Introduce staging / intermediate / marts layers
- Add data tests (uniqueness, null checks)
- Integrate Airflow for pipeline scheduling
- Replace manual execution scripts
- Add MinIO as raw storage layer
- Store raw events in Parquet format
- Dockerize the full stack (DB, dbt, Airflow)
- Enable reproducible environments
- Add Kafka for real-time event streaming
- Build API layer with FastAPI
- Implement monitoring (Grafana / Prometheus)
Transition toward an Industry 4.0-ready data platform, enabling:
- Real-time production monitoring
- Predictive maintenance
- Cross-system analytics (MES Γ ERP Γ Quality)
- Scalable and cloud-ready architecture
- Data Engineers
- Industrial Performance Managers
- BI Analysts in manufacturing
Industrial Performance & Data Engineering Project Designed and implemented by: Production Engineer & Industrial Data Analyst
MIT License β Free for educational & professional use
