Cargando…

Parallel Programming with Python.

A fast, easy-to-follow and clear tutorial to help you develop Parallel computing systems using Python. Along with explaining the fundamentals, the book will also introduce you to slightly advanced concepts and will help you in implementing these techniques in the real world. If you are an experience...

Descripción completa

Detalles Bibliográficos
Clasificación:Libro Electrónico
Autor principal: Palach, Jan
Formato: Electrónico eBook
Idioma:Inglés
Publicado: Packt Publishing, 2014.
Temas:
Acceso en línea:Texto completo
Tabla de Contenidos:
  • Cover; Copyright; Credits; About the Author; Acknowledgments; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1: Contextualizing Parallel, Concurrent, and Distributed Programming; Why use parallel programming?; Exploring common forms of parallelization; Communicating in parallel programming; Understanding shared state; Understanding message passing; Identifying parallel programming problems; Deadlock; Starvation; Race conditions; Discovering Python's parallel programming tools; The Python threading module; The Python multiprocessing module.
  • The parallel Python moduleCelery
  • a distributed task queue; Taking care of Python GIL; Summary; Chapter 2: Designing Parallel Algorithms; The divide and conquer technique; Using data decomposition; Decomposing tasks with pipeline; Processing and mapping; Identifying independent tasks; Identifying the tasks that require data exchange; Load balance; Summary; Chapter 3: Identifying a Parallelizable Problem; Obtaining the highest Fibonacci value for multiple inputs; Crawling the Web; Summary; Chapter 4: Using the threading and concurrent.futures Modules; Defining threads.
  • Advantages and disadvantages of using threadsUnderstanding different kinds of threads; Defining the states of a thread; Choosing between threading and _thread; Using threading to obtain the Fibonacci series term with multiple inputs; Crawling the Web using the concurrent.futures module; Summary; Chapter 5: Using Multiprocessing and ProcessPoolExecutor; Understanding the concept of a process; Understanding the process model; Defining the states of a process; Implementing multiprocessing communication; Using multiprocessing. Pipe; Understanding multiprocessing. Queue.
  • Using multiprocessing to compute Fibonacci series terms with multiple inputsCrawling the Web using ProcessPoolExecutor; Summary; Chapter 6: Utilizing Parallel Python; Understanding interprocess communication; Exploring named pipes; Using named pipes with Python; Writing in a named pipe; Reading named pipes; Discovering PP; Using PP to calculate the Fibonacci series term on SMP architecture; Using PP to make a distributed Web crawler; Summary; Chapter 7: Distributing Tasks with Celery; Understanding Celery; Why use Celery?; Understanding Celery's architecture; Working with tasks.
  • Discovering message transport (broker)Understanding workers; Understanding result backends; Setting up the environment; Setting up the client machine; Setting up the server machine; Dispatching a simple task; Using Celery to obtain a Fibonacci series term; Defining queues by task types; Using Celery to make a distributed Web crawler; Summary; Chapter 8: Doing Things Asynchronously; Understanding blocking, nonblocking, and asynchronous operations; Understanding blocking operations; Understanding nonblocking operations; Understanding asynchronous operations; Understanding event loop.