Creating Robust Deep Neural Networks With Coded Distributed Computing for IoT Systems

Ramyad Hadidi, Jiashen Cao, Hyesoon Kim

Introduction

As Artificial Intelligence migrates toward the "edge," distributing heavy Deep Neural Network (DNN) computations across clusters of IoT devices, such as Raspberry Pis, has become a common strategy. However, these environments are inherently unreliable. Unstable wireless latencies and hardware constraints often lead to "stragglers"—nodes that take significantly longer than others—or outright node failures. Traditional solutions like Modular Redundancy (e.g., 2MR) double the hardware requirements, a cost that is often prohibitive for resource-constrained IoT systems. This paper introduces a framework using Coded Distributed Computing (CDC) to provide resilience with minimal hardware overhead.

The Challenge of IoT Reliability

In a distributed inference task, the slowest node determines the overall latency. In typical IoT clusters, the arrival times of computation results follow a distribution with a long tail, representing stragglers.

Arrival time distribution highlighting the 'straggler' problem in IoT networks.

When a node fails or lags significantly, the missing data can lead to catastrophic failures in the inference pipeline. Without a robust recovery mechanism, even minor data loss in a single layer can render a model's predictions useless.

The CDC Approach: Resilience through Coding

The researchers propose leveraging CDC, a technique inspired by error-correction codes, to achieve robustness with a constant cost—adding just one extra device ($N+1$) instead of doubling the cluster ($2N$).

Matrix-Level Integration

Since DNN layers are fundamentally composed of General Matrix-Matrix Multiplications (GEMM), the authors integrate coding at the math library level. By applying coding to the weights offline, the system can compute a "parity" result. Specifically, for Output Splitting in Fully Connected layers and Channel Splitting in Convolutional layers, the weights of multiple nodes are summed into a single parity node.

Seamless Recovery

If a node fails or becomes a straggler, the system reconstructs the missing result through a simple subtraction between the parity node's output and the surviving nodes' outputs. This process happens almost instantly, providing near-zero recovery latency. Because this logic resides in the underlying GEMM libraries, it requires minimal changes to high-level code in frameworks like TensorFlow or Keras.

Experimental Evaluation

The approach was tested on a cluster of 12 Raspberry Pi 3 nodes using standard benchmarks including LeNet-5, Inception v3, AlexNet, C3D, and VGG16.

Key Results

The CDC framework demonstrates significant improvements in both performance and reliability.

Resilience to Data Loss

The authors observed that without coding, losing even a small percentage of data in a single layer causes destructive accuracy drops. The CDC method entirely recovers this loss, maintaining model performance even under failure conditions.

Impact of data loss on LeNet-5 accuracy, demonstrating the fragility of uncoded distributed DNNs.

Performance Gains

In a 4-node system, using the parity node for proactive straggler mitigation improved performance by up to 35%. By "racing" the network noise and ignoring the slowest node in every inference pass, the system avoids the bottleneck of the long-tail latency distribution. In a real-world case study with AlexNet, a single node failure caused a 2.4x slowdown in standard systems, whereas the CDC-enabled system experienced no slowdown or service interruption.

Conclusion and Future Work

By adding a single "coded" device, this framework achieves hardware-efficient resilience for edge AI. While highly effective for Output and Channel splitting, future work is needed to address Input and Spatial splitting, where runtime coding costs are higher. Additionally, extending the system to tolerate multiple simultaneous failures remains an area for further development.

Summary updated

BibTeX
@misc{hadidi2021creating,
  author = {Ramyad Hadidi and Jiashen Cao and Hyesoon Kim},
  title = {{Creating Robust Deep Neural Networks With Coded Distributed Computing for IoT Systems}},
  year = {2021},
  eprint = {2104.04447},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2104.04447},
}
Figure