Skip to main content

Accelerating Machine Learning Algorithms with TensorFlow Using Thread Mapping Policies

  • Conference paper
  • First Online:
High Performance Computing (CARLA 2020)

Abstract

Machine Learning (ML) algorithms are increasingly being used in various scientific and industrial problems, with the time of execution of these algorithms as an important concern. In this work, we explore mappings of threads in multi-core architectures and their impact on new ML algorithms running with Python and TensorFlow. Using smart thread mapping, we were able to reduce the execution time of both training and inference phases for up to 46% and 29%, respectively.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    Full companion material at https://github.com/MatheusWoeffel/thread-data-mapping.

References

  1. Broquedis, F., Furmento, N., Goglin, B., Namyst, R., Wacrenier, P.-A.: Dynamic task and data placement over NUMA architectures: an OpenMP runtime perspective. In: Müller, M.S., de Supinski, B.R., Chapman, B.M. (eds.) IWOMP 2009. LNCS, vol. 5568, pp. 79–92. Springer, Heidelberg (2009). https://doi.org/10.1007/978-3-642-02303-3_7

    Chapter  MATH  Google Scholar 

  2. Castro, M., Góes, L.F.W., Méhaut, J.F.: Adaptive thread mapping strategies for transactional memory applications. J. Parallel Distrib. Comput. 74(9), 2845–2859 (2014)

    Article  Google Scholar 

  3. Cruz, E.H., Diener, M., Alves, M.A., Pilla, L.L., Navaux, P.O.: LAPT: a locality-aware page table for thread and data mapping. Parallel Comput. 54, 59–71 (2016)

    Article  Google Scholar 

  4. Cruz, E.H., Diener, M., Serpa, M.S., Navaux, P.O.A., Pilla, L., Koren, I.: Improving communication and load balancing with thread mapping in manycore systems. In: 2018 26th Euromicro International Conference on Parallel, Distributed and Network-Based Processing (PDP), pp. 93–100. IEEE (2018)

    Google Scholar 

  5. Culkin, R., Das, S.R.: Machine learning in finance: the case of deep learning for option pricing. J. Invest. Manag. 15(4), 92–100 (2017)

    Google Scholar 

  6. Diener, M., Cruz, E.H., Alves, M.A., Navaux, P.O., Busse, A., Heiss, H.U.: Kernel-based thread and data mapping for improved memory affinity. IEEE Trans. Parallel Distrib. Syst. 27(9), 2653–2666 (2015)

    Article  Google Scholar 

  7. Diener, M., Cruz, E.H., Pilla, L.L., Dupros, F., Navaux, P.O.: Characterizing communication and page usage of parallel applications for thread and data mapping. Perform. Eval. 88, 18–36 (2015)

    Article  Google Scholar 

  8. Eastep, J., Wingate, D., Agarwal, A.: Smart data structures: an online machine learning approach to multicore data structures. In: Proceedings of the 8th ACM International Conference on Autonomic Computing, pp. 11–20 (2011)

    Google Scholar 

  9. He, J., Chen, W., Tang, Z.: NestedMP: enabling cache-aware thread mapping for nested parallel shared memory applications. Parallel Comput. 51, 56–66 (2016)

    Article  Google Scholar 

  10. Ignatov, A.: AI Benchmark. https://pypi.org/project/ai-benchmark/ (2020). Accessed 29 March 2020

  11. Ignatov, A., et al.: AI benchmark: running deep neural networks on android smartphones. In: Proceedings of the European Conference on Computer Vision (ECCV) (2018)

    Google Scholar 

  12. Ignatov, A., et al.: AI benchmark: all about deep learning on smartphones in 2019. In: 2019 IEEE/CVF International Conference on Computer Vision Workshop (ICCVW), pp. 3617–3635. IEEE (2019)

    Google Scholar 

  13. Intel: Intel TensorFlow. https://pypi.org/project/intel-tensorflow/ (2020). Accessed. In: 29 May 2020

  14. Kandemir, M., Ozturk, O., Muralidhara, S.P.: Dynamic thread and data mapping for NoC based CMPS. In: 2009 46th ACM/IEEE Design Automation Conference, pp. 852–857. IEEE (2009)

    Google Scholar 

  15. Mazouz, A., Barthou, D., et al.: Performance evaluation and analysis of thread pinning strategies on multi-core platforms: case study of SPEC OMP applications on intel architectures. In: 2011 International Conference on High Performance Computing & Simulation, pp. 273–279. IEEE (2011)

    Google Scholar 

  16. Owens, J.D., Houston, M., Luebke, D., Green, S., Stone, J.E., Phillips, J.C.: GPU computing. Proc. IEEE 96(5), 879–899 (2008)

    Article  Google Scholar 

  17. Perols, J.: Financial statement fraud detection: an analysis of statistical and machine learning algorithms. Auditing J. Pract. Theory 30(2), 19–50 (2011)

    Article  Google Scholar 

  18. Serpa, M.S., Krause, A.M., Cruz, E.H., Navaux, P.O.A., Pasin, M., Felber, P.: Optimizing machine learning algorithms on multi-core and many-core architectures using thread and data mapping. In: 2018 26th Euromicro International Conference on Parallel, Distributed and Network-based Processing (PDP), pp. 329–333. IEEE (2018)

    Google Scholar 

  19. Serpa, M.S., et al.: Memory performance and bottlenecks in multicore and GPU architectures. In: 2019 27th Euromicro International Conference on Parallel, Distributed and Network-Based Processing (PDP), pp. 233–236. IEEE (2019)

    Google Scholar 

  20. Stavens, D.M., et al.: Learning to drive: perception for autonomous cars. Ph.D. Thesis, Citeseer (2011)

    Google Scholar 

  21. You, Y., Buluç, A., Demmel, J.: Scaling deep learning on GPU and knights landing clusters. In: Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, pp. 1–12 (2017)

    Google Scholar 

  22. Ştirb, I.: NUMA-BTDM: a thread mapping algorithm for balanced data locality on NUMA systems. In: 2016 17th International Conference on Parallel and Distributed Computing, Applications and Technologies (PDCAT), pp. 317–320 (2016)

    Google Scholar 

Download references

Acknowledgments

This work has been partially supported by Petrobras (2016/00133-9, 2018/00263-5) and Green Cloud project (2016/2551-0000 488-9), from FAPERGS and CNPq Brazil, program PRONEX 12/2014. We also thank RICAP, partially funded by the Ibero-American Program of Science and Technology for Development (CYTED), Ref. 517RT0529.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Matheus W. Camargo .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2021 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Camargo, M.W., Serpa, M.S., Carastan-Santos, D., Carissimi, A., Navaux, P.O.A. (2021). Accelerating Machine Learning Algorithms with TensorFlow Using Thread Mapping Policies. In: Nesmachnow, S., Castro, H., Tchernykh, A. (eds) High Performance Computing. CARLA 2020. Communications in Computer and Information Science, vol 1327. Springer, Cham. https://doi.org/10.1007/978-3-030-68035-0_5

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-68035-0_5

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-68034-3

  • Online ISBN: 978-3-030-68035-0

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics