官术网_书友最值得收藏!

Introduction

Although Python is not generally considered one of the fastest language (which is somewhat unfair), it is possible to achieve excellent performance with the appropriate methods. This is the objective of this chapter and the next. This chapter describes how to evaluate (profile) what makes a program slow, and how this information can be used to optimize the code and make it more efficient. The next chapter will deal with more advanced high-performance computing methods that should only be tackled when the methods described here are not sufficient.

The recipes of this chapter are organized into three parts:

  • Time and memory profiling: Evaluating the performance of your code
  • NumPy optimization: Using NumPy more efficiently, particularly with large arrays
  • Memory mapping with arrays: Implementing memory mapping techniques for out-of-core computations on huge arrays
主站蜘蛛池模板: 鄂尔多斯市| 中牟县| 嵩明县| 临洮县| 秦皇岛市| 黄梅县| 澄迈县| 惠东县| 高唐县| 隆回县| 柳江县| 淅川县| 敖汉旗| 大名县| 广宗县| 女性| 石泉县| 五华县| 体育| 镇原县| 恩平市| 屏东市| 万安县| 巩留县| 莱州市| 谢通门县| 麻城市| 临颍县| 绵竹市| 彩票| 东阿县| 田阳县| 平武县| 绿春县| 安溪县| 张家港市| 江北区| 名山县| 灵山县| 西充县| 吉首市|