Embedding Table Sharding for Deep Learning Training Latency

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Neural networks face inefficiencies in training due to high communication costs and memory requirements when using sparse allreduce operations for large embedding tables, which hinder scalability and increase latency and memory footprints.

Innovation Solution

The approach involves treating small embedding table gradients as dense gradients and employing vertical splitting of larger tables into smaller portions, allowing for efficient communication and processing across multiple nodes using all-to-all operations, thereby reducing latency and memory usage.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If sparse allreduce operations are used for large embedding tables, then gradient updates can be performed, but communication costs and memory requirements increase significantly

Engineering Contradiction:
Improvegradient update capabilityVSAvoidcommunication cost
Core Design Contradiction:
ReliabilityVSLoss of energy

Solution Approach 1:

The embedding table is divided into multiple sharded portions distributed across different compute nodes. Each node maintains only a subset of the embedding table entries, reducing individual memory requirements. During forward propagation, lookup entries are gathered from relevant shards, and during backward propagation, gradients are distributed to the appropriate shards, eliminating the need for full-table communication.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent introduces a new dimension of organization by sharding embedding tables across multiple nodes rather than maintaining them centrally. This dimensional transformation allows the system to handle large embedding tables by distributing them spatially across the compute cluster, reducing communication overhead through targeted gradient transmission to specific shards.

Inventive Principle:
Principle #17Another dimension (Dimensionality change)

2Reliability

If sparse allreduce operations are used for large embedding tables, then gradient updates can be performed, but memory requirements increase

Engineering Contradiction:
Improvegradient update capabilityVSAvoidmemory footprint
Core Design Contradiction:
ReliabilityVSQuantity of substance

Solution Approach 1:

The embedding table is segmented into multiple sharded portions, with each compute node storing only a subset of entries. This segmentation reduces the memory footprint at each node while maintaining the ability to perform complete gradient updates through coordinated communication during backward propagation.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

Each compute node maintains local copies of only the embedding table entries relevant to its assigned parameters. This local quality optimization reduces memory requirements at each node while ensuring that gradient updates can be performed efficiently by communicating only with nodes holding the relevant shards.

Inventive Principle:
Principle #3Local quality

3Adaptability or versatility

If embedding tables are distributed across multiple nodes, then scalability is improved, but communication latency increases

Engineering Contradiction:
ImprovescalabilityVSAvoidcommunication latency
Core Design Contradiction:
Adaptability or versatilityVSLoss of time

Solution Approach 1:

The embedding table is segmented and distributed across multiple compute nodes, enabling the system to scale to larger models and datasets. During training, only the necessary shards are communicated between nodes, reducing overall communication latency compared to centralized approaches while maintaining scalability.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

Embedding table shards are pre-distributed to compute nodes before training begins. This preliminary action eliminates the need for repeated full-table communications during training, reducing latency by ensuring that each node has immediate access to its assigned shards without requiring frequent synchronized updates.

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS20240037378A1Accelerated scale-out performance of deep learning training workload with embedding tables
Publication Date: 2024.02.01 INTEL CORP
  • US20240037378A1 patent drawing
  • US20240037378A1 patent drawing
  • US20240037378A1 patent drawing

AI summary

Systems, apparatuses and methods may provide for technology that identifies an embedding table associated with a neural network. The neural network is associated with a plurality of compute nodes. The technology further identifies a number of entries of the embedding table, and determines whether to process gradients associated with the embedding table as dense gradients or sparse gradients based on the number of entries.