Goal
Replace incomplete TensorFlow Federated implementation with modern Flower framework.
Background
Current State (TFF):
- TensorFlow Federated 0.40.0
- Impossible to install (dependency conflicts)
- Never successfully used botnet data (used EMNIST instead)
- Simulation-only, not production-ready
Target (Flower):
- Modern, actively maintained
- Better documentation
- Framework-agnostic
- Production deployment support
Implementation
Architecture
src/federated_learning/
├── __init__.py
├── flower/
│ ├── __init__.py
│ ├── server.py # Flower server
│ ├── client.py # Device clients
│ └── strategy.py # Custom FedAvg
├── simulation/
│ ├── __init__.py
│ └── run_simulation.py # FL simulation
└── utils/
├── __init__.py
└── aggregation.py
Components
Server (server.py):
- Orchest rates federated training
- Aggregates client updates
- Custom FedAvg strategy
Client (client.py):
- One client per IoT device (9 total)
- Local training on device data
- Send updates to server
Simulation (run_simulation.py):
- Simulated FL environment
- Test before deployment
Tasks
Experiments
- Baseline: Centralized training (all devices)
- Local: Per-device models (no aggregation)
- Federated: Flower FL (FedAvg)
Metrics:
- Accuracy (global and per-device)
- Communication rounds
- Training time
- Model size
Research Questions
- Does FL maintain accuracy vs centralized?
- Can we achieve device-specific personalization?
- What is the communication cost?
- How does it scale?
Related
Priority
HIGH - Core feature for federated learning capability
Goal
Replace incomplete TensorFlow Federated implementation with modern Flower framework.
Background
Current State (TFF):
Target (Flower):
Implementation
Architecture
Components
Server (
server.py):Client (
client.py):Simulation (
run_simulation.py):Tasks
Experiments
Metrics:
Research Questions
Related
Priority
HIGH - Core feature for federated learning capability