Parallel map
A parallel map applies a computation concurrently to multiple inputs and produces corresponding results.
Deep Learning with JAX
The JAX mapping transformation that parallelizes a computation across multiple local devices.
- How it is used
- Parallelizes independent chunks across local accelerators for SPMD computation, including data-parallel neural-network training.
- How deep it goes
- Explains device setup, input reshaping, mapping parameters, collectives, nested transformations, training, and multihost execution.
- Examples
- Demonstrates parallel dot products, CPU device emulation, reshaped vector batches, and data-parallel MNIST-style training.
- What you can do after
- Apply pmap() to split array workloads across local devices and aggregate results or gradients with collective operations.
Clojure: The Essential Reference
pmap is a Clojure function that applies a function to one or more collections in parallel and returns a lazy sequence of results in input order.
- How it is used
- Applies independent collection transformations in parallel while retaining lazy, ordered sequence consumption.
- How deep it goes
- Explains contracts, laziness, ordering, chunking, exceptions, and performance tradeoffs, but does not provide a transducer form.
- Examples
- Uses elementwise addition, delayed printing, uneven sleeps, chunked evaluation, and Criterium benchmarks.
- What you can do after
- Apply pmap to suitable independent workloads and evaluate whether chunking or sequential map better fits the cost profile.
Read how Clojure: The Essential Reference explains parallel map →
Related concepts
- pcallsused by · pcalls is a Clojure function that invokes multiple zero-argument functions in parallel and returns their results as a lazy sequence.
- pvaluesused by · pvalues is a Clojure macro that evaluates multiple expressions in parallel and returns their results as a lazy sequence.
- parallelismimplements · Parallelism is the execution of multiple independent tasks or computational operations at the same time rather than sequentially.
- mapalternative to · Map is an operation that applies a function to values in a collection or computational context and returns the results while preserving the structure or context.
- SPMDequivalent to · SPMD is a parallel programming model in which multiple program instances execute the same code while operating on different data.
- sequenceproduces · A sequence is an ordered collection of elements whose positions determine the order in which they are arranged or traversed.
Questions about parallel map
What is parallel map?
A parallel map applies a computation concurrently to multiple inputs and produces corresponding results.
Which Manning books explain parallel map?
Deep Learning with JAX and Clojure: The Essential Reference.
What is the difference between parallel map and map?
A parallel map applies a computation concurrently to multiple inputs and produces corresponding results. Map is an operation that applies a function to values in a collection or computational context and returns the results while preserving the structure or context.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

