Parallelism.jl

Parallelism._tmap_with_partitionMethod
_tmap_with_partition(f, xss...; basesize)

An internal helper for tmap that handles the basesize > 1 case. Works for basesize == 1, but less efficent; since it breaks things up into single item slices then stiches them back together again.

source
Parallelism.robust_pmapMethod
robust_pmap(f::Function, xs::Any, num_retries::Int=3)

A pmap function with retries for common network errors.

source
Parallelism.tmapMethod
tmap(f, xs...; basesize=1)

Multithreaded version of map. basesize controls the minimum number of items from xs to process per @spawned task.

Tip

basesize should be set high enough that proccessing that many items takes about ~1ms. This is to counter the ~50μs overhead it takes to dispatch work to a thread. If the function takes >1ms per call, then basesize=1 is recommended.

source
Parallelism.tmap_with_warmupMethod
tmap_with_warmup(f, xs...; basesize=1)

Similar to tmap, but runs the first call single threaded, before multithreading the remainnder. This is useful for dealing with things that benifit from something happening on first run. Which might be related to caching values, or some compilation troubles.

basesize controls the minimum number of items from xs to process per @spawned task.

See tmap for more details

source