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

Summary

Algorithmic optimization can improve how your application scales as we process increasingly large data. In this chapter, we demonstrated use-cases and running times of the most common data structures available in Python, such as lists, deques, dictionaries, heaps, and tries. We also covered caching, a technique that can be used to trade some space, in memory or on-disk, in exchange for increased responsiveness of an application. We also demonstrated how to get modest speed gains by replacing for-loops with fast constructs, such as list comprehensions and generator expressions.

In the subsequent chapters, we will learn how to improve performance further using numerical libraries such as numpy, and how to write extension modules in a lower-level language with the help of Cython.

主站蜘蛛池模板: 施秉县| 虎林市| 望城县| 韩城市| 班玛县| 新蔡县| 柳河县| 同心县| 兰考县| 苏尼特左旗| 利川市| 揭阳市| 珲春市| 鄂伦春自治旗| 开化县| 故城县| 察雅县| 进贤县| 玛纳斯县| 万盛区| 白沙| 科技| 江陵县| 满城县| 阳谷县| 康马县| 翁牛特旗| 阆中市| 武清区| 上虞市| 炎陵县| 罗山县| 蕲春县| 郧西县| 栖霞市| 安化县| 齐齐哈尔市| 那坡县| 嘉峪关市| 错那县| 吉安县|