In many machine learning applications, e.g., tree-based ensembles, floating point numbers are extensively utilized due to their expressiveness. Nowadays performing data analysis on embedded devices from dynamic data masses becomes available, but such systems often lack hardware capabilities to process floating point numbers, introducing large overheads for their processing. Even if such hardware is present in general computing systems, using integer operations instead of floating point operations promises to reduce operation overheads and improve the performance. In this paper, we provide \mdname, a full precision floating point comparison for random forests, by only using integer and logic operations. To ensure the same functionality preserves, we formally prove the correctness of this comparison. Since random forests only require comparison of floating point numbers during inference, we implement \mdname~in low level realizations and therefore eliminate the need for floating point hardware entirely, by keeping the model accuracy unchanged. The usage of \mdname~basically boils down to a one-by-one replacement of conditions: For instance, a comparison statement in C: if(pX[3]<=(float)10.074347) becomes if((*(((int*)(pX))+3))<=((int)(0x41213087))). Experimental evaluation on X86 and ARMv8 desktop and server class systems shows that the execution time can be reduced by up to $\approx 30\%$ with our novel approach.
翻译:在许多机器学习应用程序中,例如树基编组中,浮点数因其清晰度而被广泛使用。现在,通过动态数据质量对嵌入设备进行数据分析,可以使用动态数据质量提供数据分析,但这种系统往往缺乏硬件能力来处理浮动点数,为处理这些系统引入大量间接费用。即使一般计算系统中存在这类硬件,使用整数操作而不是浮动点操作,有可能减少运行间接费用并改进性能。在本文中,我们仅使用整数和逻辑操作,为随机森林提供一个全精密的浮动点比较。为了确保相同的功能保存,我们正式证明这一比较的正确性。由于随机森林只需要在推断过程中对浮动点数进行比较,因此,我们通过保持模型精确性能来实施\mdname~因此完全消除对浮动点硬件的需求。使用 mdname- 基本熔化为一对一对一的版本方法:例如,我们使用一个比较声明:如果(pX3)_(float)10.043) 和(sal_x_x47) 执行((Xint*) 和(xxxxx_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx