|
- 2018
采用机器学习算法的软件能耗感知模型及其应用
|
Abstract:
针对软件开发人员不了解代码的能耗,或者即使能测得软件运行时的能耗但由于缺乏对影响能耗的各因素了解的问题,在对4种机器学习算法实验的基础上,选用岭回归算法建立了以软件性能事件为特征的软件能耗模型。以收集的软件能耗测量值和软件性能事件数据作为训练样本,利用岭回归机器学习算法建立平均能耗模型,用平均能耗模型来预测其他软件的平均能耗;并在此基础上,利用软件运行的实时特征提出了实时的能耗模型。实验结果表明:以测量的能耗为基准,采用所提出的平均能耗模型对软件能耗进行预测的误差率在9%以内;与平均能耗模型相比,实时能耗模型的预测误差率更低。采用本文所提出的两种能耗模型,软件设计人员不需要对自己的软件进行测量和训练就可以较准确地估算出软件的能耗并能解释能耗产生的原因,最后根据预测结果对软件的能效进行优化。
An energy consumption model for softwares using machine learning is proposed to address the problem that software developers either are usually not aware of the specific energy consumption of their codes, or may measure the energy consumption of the application softwares using some tools but do not understand the factors which affect energy consumption and the relationship among them. The Ridge machine learning algorithm is adopted based on testings of 4 different machine learning algorithms to establish the model for estimating the software energy consumption characterized by software performance events. First, the collected measurement values of energy consumptions and the data of the software performance events of a set of softwares are used as the training samples, and the machine learning algorithm is applied to build up the energy consumption model. Then the average energy consumption of any other software is estimated using this model. On this basis, a real??time program energy consumption model for the running programs is established. Experimental results show that the energy consumption prediction error given by the proposed average energy consumption model is less than 9%. A comparison with the average energy consumption model shows that the real??time program energy consumption model further reduces the prediction error. When the software designers use the proposed model to get the energy consumption of their codes, they are not required to measure or train their own software. Not only can the energy consumption of the software be accurately estimated, but also the causes of energy consumption can be explained, and the energy efficiency of the software can be optimized according to the prediction result
[1] | [6]SEO C, MALEK S, MEDVIDOVIC N. Component??level energy consumption estimation for distributed java??based software systems [C]∥Proceedings of the International Symposium on Component??Based Software Engineering. Berlin, Germany: Springer??Verlag, 2008: 97??113. |
[2] | [7]CHEN Hui, LI Youhuizi, SHI Weisong. Fine??grained power management using process??level profiling [J]. Sustainable Computing:Informatics and Systems, 2012, 2(1): 33??42. |
[3] | [8]SHYE A, SCHOLBROCK B, MEMIK G. Into the wild: studying real user activity patterns to guide power optimizations for mobile architectures [C]∥Proceedings of the 42nd Annual IEEE/ACM International Symposium on Microarchitecture. Piscataway, NJ, USA: IEEE, 2009: 168??178. |
[4] | [14]Anon. Perf [EB/OL]. (2015??05??05)[2017??06??05]. https: ∥perf??wiki??kernel??org/index??php/Tutorial. |
[5] | [15]Anon. Programming tasks [EB/OL]. (2015??09??29)[2017??06??05]. http: ∥rosettacode??org/wiki/Category: Programming_Tasks. |
[6] | [16]Anon. SPEC CPU 2006 [EB/OL]. (2008??05??22)[2017??06??05]. http: ∥www??spec??org/cpu2006/. |
[7] | [20]HASTIE T, TIBSHIRANI R, FRIEDMAN J. Linear methods for regression in the elements of statistical learning: data mining, inference, and prediction [M]∥ Springer Series in Statistics. Berlin, Germany: Springer, 2008: 43??52. |
[8] | [1]HEDDEGHEM W V, LAMBERT S, LANNOO B, et al. Trends in worldwide ICT electricity consumption from 2007 to 2012 [J]. Computer Communications. 2014, 50(1): 64??76. |
[9] | [2]AHMAD W, OLZENSPIESP K F H, STOELINGA M, et al. Green computing: power optimisation of VFI??based real??time multiprocessor dataflow applications [C]∥Proceedings of the 2015 Euromicro Conference on Digital System Design. Piscataway, NJ, USA: IEEE, 2015: 272??275. |
[10] | [3]GE Rong, VOGT R, MAJUMDER J, et al. Effects of dynamic voltage and frequency scaling on a K20 GPU [C]∥Proceedings of the 2013 42nd International Conference on Parallel Processing. Piscataway, NJ, USA: IEEE, 2013: 826??833. |
[11] | [4]MARTONOSI M, TIWARI V, BROOKS D. Wattch: a framework for architectural??level power analysis and optimization [C]∥Proceedings of the 27th International Symposium on Computer Architecture. Piscataway, NJ, USA: IEEE, 2000: 83??94. |
[12] | [5]BRANCO D. Impact of GCC optimization levels in energy consumption during C/C++program execution [C]∥Proceedings of the 13th IEEE International Scientific Conference on Informatics. Piscataway, NJ, USA: IEEE, 2015: 52??56. |
[13] | [21]Anon. Running average power limit??rapl [EB/OL]. (2014??06??06)[2017??06??05]. https: ∥01??org/zh/blogs /2014/running??average??power??limit??rapl. |
[14] | [22]Anon. Nvidia management library NVML [EB/OL]. (2017??10??31)[2017??06??05]. https: ∥developer?? nvi dia??com/nvidia??management??library??nvml. |
[15] | [23]Anon. Intel?k Xeon PhiTM coprocessor developer’s quick start guide [EB/OL]. (2012??12??01)[2017??06??05]. https: ∥software??intel??com/en??us/articles/intel??xeon??phi??coprocessor??developers??quick??start??guide. |
[16] | [9]GURUMURTHI S, SIVASUBRAMANIAM A, IRWIN M J, et al. Using complete machine simulation for software power estimation: the SoftWatt approach [C]∥Proceedings of the 8th International Symposium on High??Performance Computer Architecture. Piscataway, NJ, USA: IEEE, 2002: 141??150. |
[17] | [10]ZHANG Lide, TIWANA B, DICK R P, et al. Accurate online power estimation and automatic battery behavior based power model generation for smartphones [C]∥Proceedings of the 2010 IEEE/ACM/IFIP International Conference on Hardware/Software Codesign and System Synthesis. Piscataway, NJ, USA: IEEE, 2010: 105??114. |
[18] | [11]GE Rong, FENG Xizhou. ETune: a power analysis framework for data??intensive computing [C]∥Proceedings of the 41st International Conference on Parallel Processing Workshops. Piscataway, NJ, USA: IEEE, 2012: 254??261. |
[19] | [12]PATHAK A, HU Y C, ZHANG M, et al. Fine??grained power modeling for smartphones using system call tracing [C]∥Proceedings of the 6th Conference on Computer Systems. New York, USA: ACM, 2001: 153??168. |
[20] | [13]AGGARWAL K, ZHANG Chenlei, CAMPBELL J C, et al. The power of system call traces: predicting the software energy consumption impact of changes [C]∥Proceedings of the 24th International Conference on Computer Science and Software Engineering. New York, USA: ACM, 2014: 219??233. |
[21] | [17]Anon. SPEC OMP 2012. [EB/OL]. (2015??05??11)[2017??06??05]. http: ∥www??spec??org/omp2012/. |
[22] | [18]ZECENA I, BURTSCHER M, JIN T D, et al. Evaluating the performance and energy efficiency of n??body codes on multi??core CPUs and GPUs [C]∥ Proceedings of the 2013 32nd IEEE International Performance Computing and Communications Conference. Piscataway, NJ, USA: IEEE, 2013: 1??8. |
[23] | [19]Anon. NPB3??0 [EB/OL]. (2016??03??21)[2017??06??05]. https: ∥www??nas??nasa??gov/publications/npb?? html. |
[24] | [24]ZONG Ziliang, GE Rong, GU Qijun. Marcher: a heterogeneous system supporting energy??aware high performance computing and big data analytics [J]. Big Data Research, 2017, 8: 27??38. |