We present RecD (Recommendation Deduplication), a suite of end-to-end infrastructure optimizations across the Deep Learning Recommendation Model (DLRM) training pipeline. RecD addresses immense storage, preprocessing, and training overheads caused by feature duplication inherent in industry-scale DLRM training datasets. Feature duplication arises because DLRM datasets are generated from interactions. While each user session can generate multiple training samples, many features' values do not change across these samples. We demonstrate how RecD exploits this property, end-to-end, across a deployed training pipeline. RecD optimizes data generation pipelines to decrease dataset storage and preprocessing resource demands and to maximize duplication within a training batch. RecD introduces a new tensor format, InverseKeyedJaggedTensors (IKJTs), to deduplicate feature values in each batch. We show how DLRM model architectures can leverage IKJTs to drastically increase training throughput. RecD improves the training and preprocessing throughput and storage efficiency by up to 2.49x, 1.79x, and 3.71x, respectively, in an industry-scale DLRM training system.
translated by 谷歌翻译
Deep learning based recommendation models (DLRM) are widely used in several business critical applications. Training such recommendation models efficiently is challenging primarily because they consist of billions of embedding-based parameters which are often stored remotely leading to significant overheads from embedding access. By profiling existing DLRM training, we observe that only 8.5% of the iteration time is spent in forward/backward pass while the remaining time is spent on embedding and model synchronization. Our key insight in this paper is that access to embeddings have a specific structure and pattern which can be used to accelerate training. We observe that embedding accesses are heavily skewed, with almost 1% of embeddings represent more than 92% of total accesses. Further, we observe that during training we can lookahead at future batches to determine exactly which embeddings will be needed at what iteration in the future. Based on these insight, we propose Bagpipe, a system for training deep recommendation models that uses caching and prefetching to overlap remote embedding accesses with the computation. We designed an Oracle Cacher, a new system component which uses our lookahead algorithm to generate optimal cache update decisions and provide strong consistency guarantees. Our experiments using three datasets and two models shows that our approach provides a speed up of up to 6.2x compared to state of the art baselines, while providing the same convergence and reproducibility guarantees as synchronous training.
translated by 谷歌翻译
深度学习推荐模型(DLRM)是广泛的,占据了相当多的数据中心足迹,并每年增长超过1.5倍。使用模型尺寸很快在Tberytes范围内,利用存储类(SCM)的推理,可以降低功耗和成本。本文评估将内存层级扩展到DLRM的主要挑战,并提出了通过软件定义内存提高性能的不同技术。我们展示了基础技术,如NAND Flash和3DXP的差异化,并涉及现实世界场景,从而可以节省5%至29%。
translated by 谷歌翻译
基于深度学习的模型占主导地位的生产推荐系统的当前景观。此外,近年来目睹了模型规模的指数增长 - 从谷歌的2016年模型,最新的Facebook的型号有10亿个参数,具有12万亿参数。型号容量的每次跳跃都有显着的质量增强,这使我们相信100万亿参数的时代即将来临。然而,即使在工业规模数据中心内,这些模型的培训也在挑战。这种困难是从训练计算的惊人的异质性继承 - 模型的嵌入层可以包括总模型尺寸的99.99%,这是极其内存密集的;虽然其余的神经网络越来越多地计算密集型。为支持培训此类巨大模式,迫切需要有效的分布式培训系统。在本文中,我们通过仔细共同设计优化算法和分布式系统架构来解决这一挑战。具体而言,为了确保培训效率和训练精度,我们设计一种新型混合训练算法,其中嵌入层和密集的神经网络由不同的同步机制处理;然后,我们构建一个名为Persia的系统(短暂的并行推荐培训系统,其中包含混合加速),以支持这种混合培训算法。理论上的示范和实证研究均达到100万亿参数,以证明了波斯的系统设计和实施。我们将Pensia公开使用(在https://github.com/persiamml/persia),以便任何人都能够以100万亿参数的规模轻松培训推荐模型。
translated by 谷歌翻译
过去的几年见证了基于变压器的模型的成功,其规模和应用方案继续积极发展。变压器模型的当前景观越来越多样化:该模型大小差异很大,最大的参数是最大的。模型特性由于特征的混合物所引入的稀疏性而有所不同。目标应用程序方案可以是关键延迟或面向吞吐量的情况;部署硬件可以是具有不同类型的内存和存储等单身或多GPU系统。随着多样性的增加和变压器模型的快速发展速度,设计高性能和高效的推理系统非常具有挑战性。在本文中,我们提出了DeepSpeed推断,这是用于解决上述挑战的变压器模型推理的全面系统解决方案。深速推理包括(1)一种多GPU推理解决方案,可最大程度地减少潜伏度,同时最大化密集和稀疏变压器模型的吞吐量,当它们适合聚集的GPU内存时,以及(2)一种异质推理解决方案,该解决方案利用CPU和NVME内存中的CPU和NVME内存。除了GPU内存和计算以使高推理吞吐量具有不适合聚集GPU内存的大型推理吞吐量。对于面向延迟的方案,深速推理可将延迟降低到最新的7倍,而对于面向吞吐量的方案,延迟的潜伏期将延迟减少到1.5倍以上。此外,它通过利用数百个GPU来实现实时延迟约束下的参数量表推断,这是一个前所未有的推理。它可以比仅使用GPU的解决方案更大的25倍模型,同时提供84个TFLOPS(超过50美元的A6000峰值)。
translated by 谷歌翻译
输入管道,其摄取和转换输入数据,是培训机器学习(ML)模型的重要组成部分。然而,实现有效的输入管道有挑战性,因为它需要推理有关并行性,异步的推理和细粒度分析信息的可变性。我们对谷歌数据中心超过200万毫升工作的分析表明,大量模型培训工作可以从更快的输入数据管道中受益。与此同时,我们的分析表明,大多数工作都不饱和主机硬件,指向基于软件的瓶颈的方向。这些发现的动机,我们提出了水管工,一种用于在ML输入管道中找到瓶颈的工具。管道工使用可扩展和可解释的操作分析分析模型来自动调整Host资源约束下的并行性,预取和缓存。在五个代表性ML管道上,水管工可获得最多46倍的误配置管道的加速。通过自动化缓存,与最先进的调谐器相比,水管工获得超过40%的端到端加速。
translated by 谷歌翻译
深度学习推荐模型(DLRMS)已广泛应用于互联网公司。DLRM的嵌入表太大,无法完全适合GPU内存。我们通过利用目标数据集的ID频率统计信息来动态管理CPU和GPU内存空间中的嵌入式表的基于GPU的软件缓存方法。我们提出的软件缓存以同步更新方式有效地在GPU上培训整个DLRM。它还与广泛使用的混合平行训练方法相结合,将其缩放到多个GPU。评估我们的原型系统表明,我们只能保留GPU中嵌入参数的1.5%,以获得体面的端到端训练速度。
translated by 谷歌翻译
TensorFlow is a machine learning system that operates at large scale and in heterogeneous environments. Tensor-Flow uses dataflow graphs to represent computation, shared state, and the operations that mutate that state. It maps the nodes of a dataflow graph across many machines in a cluster, and within a machine across multiple computational devices, including multicore CPUs, generalpurpose GPUs, and custom-designed ASICs known as Tensor Processing Units (TPUs). This architecture gives flexibility to the application developer: whereas in previous "parameter server" designs the management of shared state is built into the system, TensorFlow enables developers to experiment with novel optimizations and training algorithms. TensorFlow supports a variety of applications, with a focus on training and inference on deep neural networks. Several Google services use TensorFlow in production, we have released it as an open-source project, and it has become widely used for machine learning research. In this paper, we describe the TensorFlow dataflow model and demonstrate the compelling performance that Tensor-Flow achieves for several real-world applications.
translated by 谷歌翻译
随着深度学习模型的速度较大,需要进行大型型号培训的系统级解决方案。我们展示了Amazon Sagemaker模型并行性,这是一个与Pytorch集成的软件库,并且可以使用模型并行性和其他内存节省功能轻松培训大型模型。与现有解决方案相比,Sagemaker库的实现更通用,灵活,因为它可以自动分区和运行具有最小代码的任意模型架构上的管道并行性,并且还为张量并行度提供一般和可扩展的框架,它支持更广泛的用例,并且可以轻松应用于新培训脚本的模块化。该库还将本机Pytorch用户体验保留到更大的程度,支持模块重复使用和动态图形,同时让用户完全控制训练步骤的细节。我们评估GPT-3,Roberta,BERT和神经协作过滤的性能,并表现出对现有解决方案的竞争性能。
translated by 谷歌翻译
传统的数据湖泊通过启用时间旅行,运行SQL查询,使用酸性交易摄入数据以及可视化PBABYTE尺度数据集在云存储中,为分析工作负载提供了关键的数据基础架构。它们使组织能够分解数据孤岛,解锁数据驱动的决策,提高运营效率并降低成本。但是,随着深度学习接管常见的分析工作流程,传统数据湖泊对诸如自然语言处理(NLP),音频处理,计算机视觉和涉及非尾巴数据集的应用程序的有用程度降低。本文介绍了Deep Lake,这是一个开源湖泊,用于在Activeloop开发的深度学习应用程序。 Deep Lake保持了一项关键区别的香草数据湖的好处:它以张量的形式存储复杂数据,例如图像,视频,注释以及表格数据,并将数据迅速流式传输到网络上(a )张量查询语言,(b)浏览器可视化引擎或(c)不牺牲GPU利用率的深度学习框架。可以从Pytorch,Tensorflow,Jax,与许多MLOPS工具集成在一起的数据集。
translated by 谷歌翻译
A growing number of Machine Learning Frameworks recently made Deep Learning accessible to a wider audience of engineers, scientists, and practitioners, by allowing straightforward use of complex neural network architectures and algorithms. However, since deep learning is rapidly evolving, not only through theoretical advancements but also with respect to hardware and software engineering, ML frameworks often lose backward compatibility and introduce technical debt that can lead to bottlenecks and sub-optimal resource utilization. Moreover, the focus is in most cases not on deep learning engineering, but rather on new models and theoretical advancements. In this work, however, we focus on engineering, more specifically on the data loading pipeline in the PyTorch Framework. We designed a series of benchmarks that outline performance issues of certain steps in the data loading process. Our findings show that for classification tasks that involve loading many files, like images, the training wall-time can be significantly improved. With our new, modified ConcurrentDataloader we can reach improvements in GPU utilization and significantly reduce batch loading time, up to 12X. This allows for the use of the cloud-based, S3-like object storage for datasets, and have comparable training time as if datasets are stored on local drives.
translated by 谷歌翻译
基础模型正在成为主要的深度学习技术。由于模型参数和训练数据集的大规模,预处理基础模型始终耗时。除了计算密集型外,培训过程还非常密集和沟通密集。这些功能使得需要应用3D并行性,该平行性整合数据并行性,管道模型并行性和张量模型并行性,以实现高训练效率。为了实现这一目标,开发了一些自定义软件框架,例如Megatron-LM和DeepSpeed。但是,当前的3D平行框架仍然符合两个问题:i)它们对模型开发人员不透明,这些开发人员需要手动修改模型以并行化培训。 ii)它们对计算,GPU存储器和网络带宽的利用不足。我们提出了Merak,这是一个自动化的3D并行性深度学习培训框架,并具有高度资源利用。 Merak会自动使用自动模型分区仪部署,该分区仪在模型的代理表示上使用图形sharding算法。 Merak还提出了非侵入性的API,用于通过最小的代码修改来扩展基础模型培训。此外,我们在Merak设计了高性能的3D平行运行时引擎。它使用多种技术来利用可用的培训资源,包括移动的关键路径管道时间表,该计划带来了更高的计算利用率,阶段感知的重新计算,可利用空闲工作者的记忆以及子额定张量的模型并行性,这些模型并联与通信和计算重叠。 64 GPU的实验显示,Merak可以加快在最新的3D平行性框架上,具有1.5、2.5、8.3和20亿的模型框架,最高可达1.42x,1.39x,1.43x和1.61 x分别。
translated by 谷歌翻译
原则上,稀疏的神经网络应该比传统的密集网络更有效。大脑中的神经元表现出两种类型的稀疏性;它们稀疏地相互连接和稀疏活跃。当组合时,这两种类型的稀疏性,称为重量稀疏性和激活稀疏性,提出了通过两个数量级来降低神经网络的计算成本。尽管存在这种潜力,但今天的神经网络只使用重量稀疏提供适度的性能益处,因为传统的计算硬件无法有效地处理稀疏网络。在本文中,我们引入了互补稀疏性,这是一种显着提高现有硬件对双稀疏网络性能的新技术。我们证明我们可以实现高性能运行的重量稀疏网络,我们可以通过结合激活稀疏性来乘以这些加速。采用互补稀疏性,我们显示出对FPGA的推断的吞吐量和能效提高了100倍。我们分析了典型的商业卷积网络等各种内核的可扩展性和资源权衡,例如Resnet-50和MobileNetv2。我们的互补稀疏性的结果表明,重量加激活稀疏性可以是有效的缩放未来AI模型的有效组合。
translated by 谷歌翻译
图形神经网络(GNNS)将深度神经网络(DNN)的成功扩展到非欧几里德图数据,实现了各种任务的接地性能,例如节点分类和图形属性预测。尽管如此,现有系统效率低,培训数十亿节点和GPU的节点和边缘训练大图。主要瓶颈是准备GPU数据的过程 - 子图采样和特征检索。本文提出了一个分布式GNN培训系统的BGL,旨在解决一些关键思想的瓶颈。首先,我们提出了一种动态缓存引擎,以最小化特征检索流量。通过协同设计缓存政策和抽样顺序,我们发现低开销和高缓存命中率的精美斑点。其次,我们改善了曲线图分区算法,以减少子图采样期间的交叉分区通信。最后,仔细资源隔离减少了不同数据预处理阶段之间的争用。关于各种GNN模型和大图数据集的广泛实验表明,BGL平均明显优于现有的GNN训练系统20.68倍。
translated by 谷歌翻译
We study the problem of efficient generative inference for Transformer models, in one of its most challenging settings: large deep models, with tight latency targets and long sequence lengths. Better understanding of the engineering tradeoffs for inference for large Transformer-based models is important as use cases of these models are growing rapidly throughout application areas. We develop a simple analytical model for inference efficiency to select the best multi-dimensional partitioning techniques optimized for TPU v4 slices based on the application requirements. We combine these with a suite of low-level optimizations to achieve a new Pareto frontier on the latency and model FLOPS utilization (MFU) tradeoffs on 500B+ parameter models that outperforms the FasterTransformer suite of benchmarks. We further show that with appropriate partitioning, the lower memory requirements of multiquery attention (i.e. multiple query heads share single key/value head) enables scaling up to 32x larger context lengths. Finally, we achieve a low-batch-size latency of 29ms per token during generation (using int8 weight quantization) and a 76% MFU during large-batch-size processing of input tokens, while supporting a long 2048-token context length on the PaLM 540B parameter model.
translated by 谷歌翻译
Graph neural networks (GNNs) have been demonstrated to be a powerful algorithmic model in broad application fields for their effectiveness in learning over graphs. To scale GNN training up for large-scale and ever-growing graphs, the most promising solution is distributed training which distributes the workload of training across multiple computing nodes. However, the workflows, computational patterns, communication patterns, and optimization techniques of distributed GNN training remain preliminarily understood. In this paper, we provide a comprehensive survey of distributed GNN training by investigating various optimization techniques used in distributed GNN training. First, distributed GNN training is classified into several categories according to their workflows. In addition, their computational patterns and communication patterns, as well as the optimization techniques proposed by recent work are introduced. Second, the software frameworks and hardware platforms of distributed GNN training are also introduced for a deeper understanding. Third, distributed GNN training is compared with distributed training of deep neural networks, emphasizing the uniqueness of distributed GNN training. Finally, interesting issues and opportunities in this field are discussed.
translated by 谷歌翻译
预训练的模型(PTM)正在革新人工智能(AI)技术。但是,PTM培训的硬件要求非常高,使其成为一小部分人的游戏。因此,我们提出了Patrickstar系统,以降低PTM的硬件要求,并使所有人都可以使用。 Patrickstar使用CPU-GPU异质存储空间来存储模型数据。与现有作品不同,我们在内存块中组织模型数据,并在异质内存中动态分配它们。在热身迭代中收集的运行时内存统计的指导下,块在异质内存中有效地精心策划,并生成较低的CPU-GPU数据传输量和较高的带宽利用率。与零冗余优化器的共生,Patrickstar量表在多个节点上均为多个GPU。 %使用数据并行性。该系统可以在更大的型号和较大的批次大小上训练任务,这是现有工程无法完成的。实验结果表明,Patrickstar扩展了模型量表2.27和2.5倍,并且始终显示出更高的执行速度。 Patricstar还成功地在32 GPU集群上成功运行了175B GPT3培训任务。我们的代码可在https://github.com/tencent/patrickstar上公开获取。
translated by 谷歌翻译
基于von-neumann架构的传统计算系统,数据密集型工作负载和应用程序(如机器学习)和应用程序都是基本上限制的。随着数据移动操作和能量消耗成为计算系统设计中的关键瓶颈,对近数据处理(NDP),机器学习和特别是神经网络(NN)的加速器等非传统方法的兴趣显着增加。诸如Reram和3D堆叠的新兴内存技术,这是有效地架构基于NN的基于NN的加速器,因为它们的工作能力是:高密度/低能量存储和近记忆计算/搜索引擎。在本文中,我们提出了一种为NN设计NDP架构的技术调查。通过基于所采用的内存技术对技术进行分类,我们强调了它们的相似之处和差异。最后,我们讨论了需要探索的开放挑战和未来的观点,以便改进和扩展未来计算平台的NDP架构。本文对计算机学习领域的计算机架构师,芯片设计师和研究人员来说是有价值的。
translated by 谷歌翻译
气候变化所扩大的极端天气正在造成全球日益毁灭性的影响。由于高计算成本和严格的时间到解决方案限制,目前基于物理的数值天气预测(NWP)的使用限制了精度。我们报告说,数据驱动的深度学习地球系统模拟器Fourcastnet可以预测全球天气,并在接近最先进的准确性的同时,比NWP更快地产生五个量子的预测。四个超级计算系统(Selene,Perlmutter和Juwels Booster高达3,808 nvidia a100 GPU)在三个超级计算系统上进行了优化,并有效地缩放,并在混合精度中获得140.8 PETAFLOPS(该规模的峰值为11.9%)。在3,072GPU上在Juwels Booster上测量的训练四界的时间到达的时间为67.4分钟,相对于最新的NWP,在推理中,相对于最先进的NWP的时间更快。 Fourcastnet提前一周可产生准确的瞬时天气预测,使巨大的合奏更好地捕捉了极端天气,并支持更高的全球预测决议。
translated by 谷歌翻译
Large deep learning models offer significant accuracy gains, but training billions to trillions of parameters is challenging. Existing solutions such as data and model parallelisms exhibit fundamental limitations to fit these models into limited device memory, while obtaining computation, communication and development efficiency. We develop a novel solution, Zero Redundancy Optimizer (ZeRO), to optimize memory, vastly improving training speed while increasing the model size that can be efficiently trained. ZeRO eliminates memory redundancies in data-and model-parallel training while retaining low communication volume and high computational granularity, allowing us to scale the model size proportional to the number of devices with sustained high efficiency. Our analysis on memory requirements and communication volume demonstrates: ZeRO has the potential to scale beyond 1 Trillion parameters using today's hardware.We implement and evaluate ZeRO: it trains large models of over 100B parameter with super-linear speedup on 400 GPUs, achieving throughput of 15 Petaflops. This represents an 8x increase in model size and 10x increase in achievable performance over state-of-the-art. In terms of usability, ZeRO can train large models of up to 13B parameters (e.g., larger than Megatron GPT 8.3B and T5 11B) without requiring model parallelism which is harder for scientists to apply. Last but not the least, researchers have used the system breakthroughs of ZeRO to create the world's largest language model (17B parameters) with record breaking accuracy.
translated by 谷歌翻译