Harness the power of multiple computers using Python through this fast-paced informative guideAbout This Book- You'll learn to write data processing programs in Python that are highly available, reliable, and fault tolerant- Make use of Amazon Web Services along with Python to establish a powerful remote computation system- Train Python to handle data-intensive and resource hungry applicationsWho This Book Is ForThis book is for Python developers who have developed Python programs for data processing and now want to learn how to write fast, efficient programs that perform CPU-intensive data processing tasks.What You Will Learn- Get an introduction to parallel and distributed computing- See synchronous and asynchronous programming- Explore parallelism in Python- Distributed application with Celery- Python in the Cloud- Python on an HPC cluster- Test and debug distributed applicationsIn DetailCPU-intensive data processing tasks have become crucial considering the complexity of the various big data applications that are used today. Reducing the CPU utilization per process is very important to improve the overall speed of applications.This book will teach you how to perform parallel execution of computations by distributing them across multiple processors in a single machine, thus improving the overall performance of a big data processing task. We will cover synchronous and asynchronous models, shared memory and file systems, communication between various processes, synchronization, and more.Style and ApproachThis example based, step-by-step guide will show you how to make the best of your hardware configuration using Python for distributing applications.
Author(s): Francesco Pierfederici
Year: 2016
Language: English
Pages: 170
Cover
Copyright
Credits
About the Author
About the Reviewer
www.PacktPub.com
Table of Contents
Preface
Chapter 1: An Introduction to Parallel and Distributed Computing
Parallel computing
Distributed computing
Shared memory versus distributed memory
Amdahl's law
The mixed paradigm
Summary
Chapter 2: Asynchronous Programming
Coroutines
An asynchronous example
Summary
Chapter 3: Parallelism in Python
Multiple threads
Multiple processes
Multiprocess queues
Closing thoughts
Summary
Chapter 4: Distributed Applications – with Celery
Establishing a multimachine environment
Installing Celery
Testing the installation
A tour of Celery
More complex Celery applications
Celery in production
Celery alternatives – Python-RQ
Celery alternatives – Pyro
Summary
Chapter 5: Python in the Cloud
Cloud computing and AWS
Creating an AWS account
Creating an EC2 instance
Storing data in Amazon S3
Amazon elastic beanstalk
Creating a private cloud
Summary
Chapter 6: Python on an HPC Cluster
Your typical HPC cluster
Job schedulers
Running a Python job using HTCondor
Running a Python job using PBS
Debugging
Summary
Chapter 7: Testing and Debugging Distributed Applications
The big picture
Common problems – clocks and time
Common problems – software environments
Common problems – permissions and environments
Common problems – the availability of hardware resources
Challenges – the development environment
A useful strategy – logging everything
A useful strategy – simulating components
Summary
Chapter 8: The Road Ahead
The first two chapters
The tools
The cloud and the HPC world
Debugging and monitoring
Where to go next
Index