Mixed-Precision Deep Learning Based on Computational Memory

S. R. Nandakumar, Manuel Le Gallo, Christophe Piveteau, Vinay Joshi, Giovanni Mariani, Irem Boybat, Geethan Karunaratne, Riduan Khaddam-Aljameh, Urs Egger, Αναστάσιος Πετρόπουλος, Theodore Antonakopoulos, Bipin Rajendran, Abu Sebastian, Evangelos Eleftheriou

Abstract

Deep neural networks (DNNs) have revolutionized the field of artificial intelligence, achieving unprecedented success in cognitive tasks such as image and speech recognition. Training large DNNs, however, is computationally intensive, motivating the search for novel computing architectures. A computational memory unit with nanoscale resistive memory devices organized in crossbar arrays could store synaptic weights in their conductance states and perform expensive weighted summations in place. However, updating conductance states reliably is a fundamental challenge. This paper proposes a mixed-precision architecture that combines a computational memory unit performing weighted summations and imprecise updates with a digital processing unit that accumulates weight updates in high precision. A combined hardware/software training experiment using a phase-change memory (PCM) array achieves 97.73% test accuracy on MNIST, within 0.6% of the software baseline. The architecture demonstrates a 172× improvement in energy efficiency compared to a dedicated fully digital 32-bit implementation.

The Challenge of Training Efficiency

Training deep neural networks is notoriously energy-intensive, largely due to the "von Neumann bottleneck"—the constant shuffling of data between the processor and memory. In-memory computing (IMC) seeks to solve this by using crossbar arrays of memristive devices, such as Phase-Change Memory (PCM), to store weights and perform calculations directly within the memory.

However, memristive devices are inherently "non-ideal." They exhibit stochasticity, non-linearity, and asymmetry during conductance changes. When updating these analog weights directly during training, these imperfections typically lead to a significant drop in accuracy compared to standard software implementations. The challenge lies in harnessing the efficiency of analog memory without sacrificing the precision required for deep learning convergence.

The Mixed-Precision Architecture

The proposed architecture addresses these non-idealities by splitting the workload between two specialized units:

  1. Computational Memory Unit (CMU): This unit utilizes analog PCM crossbar arrays to perform the most computationally expensive parts of training—the forward and backward passes (matrix-vector multiplications). Weights are represented as the conductance states of the PCM devices.
  2. Digital Processing Unit (DPU): This unit manages weight updates. Instead of updating the PCM devices immediately, the DPU calculates gradients and accumulates them in a high-precision digital variable (denoted as $\chi$).
  3. The "Blind" Update: Only when the accumulated update in $\chi$ exceeds a specific threshold is a single-shot programming pulse sent to the PCM device. Crucially, this is a "blind" update, meaning there is no expensive "read-verify" loop to check if the device reached an exact state, significantly reducing hardware overhead.
The mixed-precision architecture showing (A) the mapping of neural network layers and (B) the interaction between the analog computational memory unit and the high-precision digital unit.

Experimental Results and Generalization

The researchers validated this approach through a physical hardware experiment using a prototype PCM chip and extended the results via high-fidelity simulations. The study evaluated the architecture across several standard benchmarks, including MNIST (MLP and GAN), CIFAR-10 (CNN), and Penn Treebank (LSTM).

  • Accuracy: The hardware-software experiment on MNIST achieved a 97.73% test accuracy, remarkably close to the 98.33% software baseline.
  • Energy Efficiency: A system-level study estimated a 172× improvement in energy efficiency for training a multilayer perceptron compared to a dedicated 32-bit digital implementation.
  • Throughput: The architecture demonstrated an 11.5× higher throughput than the digital baseline.
  • Versatility: Simulations confirmed that the architecture maintains performance across CNNs, LSTMs, and GANs, proving its applicability to diverse neural network topologies.

Key Insights and Future Outlook

A significant finding was that high precision is only strictly necessary for accumulating small weight updates over time. The actual forward and backward passes are resilient to the lower precision and noise of analog devices. Interestingly, the inherent stochasticity of PCM devices acted as a form of "natural regularization," similar to Dropout, sometimes improving generalization.

Despite these successes, challenges remain. PCM devices suffer from "conductance drift," requiring periodic refresh operations to maintain accuracy. Furthermore, while the memory arrays are efficient, peripheral circuitry like Analog-to-Digital Converters (ADCs) still consume significant power and area. Future work will focus on optimizing these peripheral components and scaling the hardware to handle larger, more complex architectures beyond the simulation domain.

Summary updated

BibTeX
@inproceedings{nandakumar2020mixed,
  author = {S. R. Nandakumar and Manuel Le Gallo and Christophe Piveteau and Vinay Joshi and Giovanni Mariani and Irem Boybat and Geethan Karunaratne and Riduan Khaddam-Aljameh and Urs Egger and Αναστάσιος Πετρόπουλος and Theodore Antonakopoulos and Bipin Rajendran and Abu Sebastian and Evangelos Eleftheriou},
  title = {{Mixed-Precision Deep Learning Based on Computational Memory}},
  booktitle = {Frontiers in Neuroscience},
  year = {2020},
  doi = {10.3389/fnins.2020.00406},
}
Figure