TreeTensor: 通过受限树状张量提升AI系统在嵌套数据上的性能
TreeTensor: Boost AI System on Nested Data with Constrained Tree-Like Tensor
AI总结:
TreeTensor通过受限树状结构提升AI系统在嵌套数据上的性能,提供高效且灵活的数据处理方法。
摘要:
张量是当今人工智能(AI)系统中最基本和最重要的数据结构。张量的自然特性,特别是内存连续性和切片独立性,使训练系统能够利用GPU等并行计算单元,同时在空间或时间维度上处理数据。然而,如果我们超越感知任务,复杂认知AI系统中的数据通常具有层次结构(即嵌套数据),并且具有各种模态。用传统固定形状的张量直接编程是不方便且低效的。为了解决这个问题,我们总结了嵌套数据的两种主要计算模式,然后提出了一种通用的嵌套数据容器:TreeTensor。通过各种约束和魔法功能,TreeTensor可以以几乎零成本应用任意函数和操作到嵌套数据中,包括一些著名的机器学习库,如Scikit-Learn、Numpy和PyTorch。我们的方法利用受限树状结构的视角系统地建模数据关系,并且可以轻松与其他方法结合,扩展更多用途,如异步执行和可变长度数据计算。详细的示例和基准测试显示,TreeTensor不仅在各种问题中提供了强大的实用性,特别是当前最复杂的AI系统之一:AlphaStar for StarCraftII,而且在没有额外开销的情况下也表现出卓越的运行时效率。我们的项目可在https://github.com/opendilab/DI-treetensor上获得。
英文摘要:
Tensor is the most basic and essential data structure of nowadays artificial intelligence (AI) system. The natural properties of Tensor, especially the memory-continuity and slice-independence, make it feasible for training system to leverage parallel computing unit like GPU to process data simultaneously in batch, spatial or temporal dimensions. However, if we look beyond perception tasks, the data in a complicated cognitive AI system usually has hierarchical structures (i.e. nested data) with various modalities. They are inconvenient and inefficient to program directly with conventional Tensor with fixed shape. To address this issue, we summarize two main computational patterns of nested data, and then propose a general nested data container: TreeTensor. Through various constraints and magic utilities of TreeTensor, one can apply arbitrary functions and operations to nested data with almost zero cost, including some famous machine learning libraries, such as Scikit-Learn, Numpy and PyTorch. Our approach utilizes a constrained tree-structure perspective to systematically model data relationships, and it can also easily be combined with other methods to extend more usages, such as asynchronous execution and variable-length data computation. Detailed examples and benchmarks show TreeTensor not only provides powerful usability in various problems, especially one of the most complicated AI systems at present: AlphaStar for StarCraftII, but also exhibits excellent runtime efficiency without any overhead. Our project is available at https://github.com/opendilab/DI-treetensor.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。