Python: Programming Efficiently

Python: Programming Efficiently
Python: Programming Efficiently

English | MP4 | AVC 1280×720 | AAC 48KHz 2ch | 2h 15m | 457 MB
eLearning | Skill level: Intermediate


Cut down on your development time by learning how to write elegant code in an efficient manner, specifically in Python—the popular and pragmatic object-oriented language. Miсhele Vаllisnеri explains how to make your Python code more expressive and concise, and leverage the most powerful features of the language. He shines a spotlight on some of the strongest third-party packages you can take advantage of, discusses object-oriented and functional programming, and shares strategies for improving the performance of your code. Michele illustrates these concepts with many intriguing examples, showing how to make 3D images and videos using photographs taken by a NASA rover on Mars, map the rover’s progress through Martian topography, draw and paint fractals, and more.

Topics include:

  • Designing efficient loops
  • Exploiting Python collections
  • Writing Pythonic code
  • Choosing the best libraries for your tasks
  • Downloading webpages with requests
  • Parsing HTML with Beautiful Soup
  • Manipulating images with Pillow
  • Making videos and drawing on maps with matplotlib
  • Serving webpages with Jinja2 and Flask
  • Working with Python classes
  • Taking advantage of functional techniques
  • Profiling CPU and memory use
  • Exploiting parallelism
+ Table of Contents

Introduction
Welcome
What you need to know
Using the exercise files

1. Installation and Setup
Install Anaconda Python distribution
Jupyter notebooks

2. Writing Python Efficiently
Overview – Writing Python efficiently
Python vs. C
Design efficient loops
Comprehensions and generators
Exploit Python collections
Write Pythonic code
Challenge – Analyze Olympic medalist data
Solution – Analyze Olympic medalist data

3. Exploiting Python Libraries
Choose the best libraries for your task
Download webpages with requests
Parse HTML with Beautiful Soup
Manipulate images with Pillow
Make movies with matplotlib
Draw on maps with matplotlib
Serve web pages with Jinja2 and Flask
Challenge – Mars map web server
Solution – Mars map web server

4. Advanced: Python Object-Oriented and Functional Programming
Object-oriented and functional Python
Divide and conquer with Python classes
Exploit class inheritance
Functional techniques in Python
Function decorators
Challenge – functional fractal
Solution – functional fractal

5. Introduction to Performance Optimization in Python
Computer architecture and optimization techniques
Time profiling
Memory profiling
Algorithm complexity
Introduction to parallelism
Challenge – Parallel search
Solution – Parallel search

Conclusion
Next steps