arXiv:2409.07853cs.LG2024-09被引 1

用混合精度训练可降低分类模型能耗7至11瓦,减少碳足迹。

Improve Machine Learning carbon footprint using Nvidia GPU and Mixed Precision training for classification models -- Part I

  • 采用Nvidia混合精度(16+32位)替代默认32位浮点计算
  • 特定超参数组合下,功耗降低7~11瓦,碳足迹同步下降
  • 适合关注绿色AI、低功耗部署的机器学习研究者

本研究是硕士论文第一部分,对比了使用默认32位浮点与Nvidia混合精度(16位和32位)训练分类模型时的功耗差异。实验在自建定制电脑上进行,通过调整批量大小、神经元数量和训练轮数构建深度神经网络(DNN)。利用多种软件采集GPU、CPU、RAM的实时功耗数据,并手动记录连接墙插的电表读数。以默认超参数的基准测试为参照,对比不同配置组合下的能耗表现。结果记录于Excel,采用描述性统计分析均值并绘图对比。结果显示,在特定超参数组合下,混合精度可使功耗降低7至11瓦;基于相同能耗数据,碳足迹亦相应减少。但需注意超参数配置不当可能影响硬件性能。尽管进行了方差分析(ANOVA)和T检验,未发现基准与实验组间具有显著统计差异。未来在多GPU集群上扩展样本量,可能改变统计结论。

原文摘要 · Abstract (English)

This is the 1st part of the dissertation for my master degree and compares the power consumption using the default floating point (32bit) and Nvidia mixed precision (16bit and 32bit) while training a classification ML model. A custom PC with specific hardware was built to perform the experiments, and different ML hyper-parameters, such as batch size, neurons, and epochs, were chosen to build Deep Neural Networks (DNN). Additionally, various software was used during the experiments to collect the power consumption data in Watts from the Graphics Processing Unit (GPU), Central Processing Unit (CPU), Random Access Memory (RAM) and manually from a wattmeter connected to the wall. A benchmarking test with default hyper parameter values for the DNN was used as a reference, while the experiments used a combination of different settings. The results were recorded in Excel, and descriptive statistics were chosen to calculate the mean between the groups and compare them using graphs and tables. The outcome was positive when using mixed precision combined with specific hyper-parameters. Compared to the benchmarking, the optimisation for the classification reduced the power consumption between 7 and 11 Watts. Similarly, the carbon footprint is reduced because the calculation uses the same power consumption data. Still, a consideration is required when configuring hyper-parameters because it can negatively affect hardware performance. However, this research required inferential statistics, specifically ANOVA and T-test, to compare the relationship between the means. Furthermore, tests indicated no statistical significance of the relationship between the benchmarking and experiments. However, a more extensive implementation with a cluster of GPUs can increase the sample size significantly, as it is an essential factor and can change the outcome of the statistical analysis.

绿色AI混合精度能耗优化碳足迹

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。