正规化数据上的线性代数
Towards Linear Algebra over Normalized Data
摘要:
在关系数据上提供机器学习(ML)是数据分析系统的主流需求。虽然几乎所有的机器学习工具都要求输入数据以单个表的形式呈现,但许多数据集都是多表的,这迫使数据科学家首先连接这些表,导致数据冗余和运行时浪费。最近关于“因子分解”ML的工作通过将ML推过连接来缓解一些特定ML算法的这个问题。但是他们的方法需要手动重写ML实现。这种零碎的方法在将这些想法扩展到其他ML算法时会产生巨大的开发开销。在本文中,我们证明了可以通过利用流行的形式代数来表示许多ML算法的计算来减轻这种开销:线性代数。我们引入了一种新的逻辑数据类型来表示规范化数据,并设计了一个代数重写规则框架,将非规范化数据上的大量线性代数操作转换为规范化数据上的操作。我们展示了这如何使我们能够自动“分解”几个流行的ML算法,从而统一和推广几个以前的作品。我们在流行的ML环境R和工业R-over-RDBMS工具中原型化我们的框架。合成和真实归一化数据的实验表明,我们的框架也产生了显着的速度提升,在真实数据上高达36倍。
英文摘要:
Providing machine learning (ML) over relational data is a mainstream requirement for data analytics systems. While almost all the ML tools require the input data to be presented as a single table, many datasets are multi-table, which forces data scientists to join those tables first, leading to data redundancy and runtime waste. Recent works on "factorized" ML mitigate this issue for a few specific ML algorithms by pushing ML through joins. But their approaches require a manual rewrite of ML implementations. Such piecemeal methods create a massive development overhead when extending such ideas to other ML algorithms. In this paper, we show that it is possible to mitigate this overhead by leveraging a popular formal algebra to represent the computations of many ML algorithms: linear algebra. We introduce a new logical data type to represent normalized data and devise a framework of algebraic rewrite rules to convert a large set of linear algebra operations over denormalized data into operations over normalized data. We show how this enables us to automatically "factorize" several popular ML algorithms, thus unifying and generalizing several prior works. We prototype our framework in the popular ML environment R and an industrial R-over-RDBMS tool. Experiments with both synthetic and real normalized data show that our framework also yields significant speed-ups, up to 36x on real data.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。