pylops_distributed.utils.backend.dask

pylops_distributed.utils.backend.dask(hardware='single', client=None, processes=False, n_workers=1, threads_per_worker=1, **kwargscluster)[source]

Dask backend initialization.

Create connection to drive computations using Dask distributed.

Parameters:
hardware : str, optional

Hardware used to run Dask distributed. Currently available options are single for single-machine distribution, ssh for SSH-bases multi-machine distribution and pbs for PBS-bases multi-machine distribution

client : str, optional

Name of scheduler (use None for hardware=single).

processes : str, optional

Whether to use processes (True) or threads (False).

n_workers : int, optional

Number of workers

threads_per_worker : int, optional

Number of threads per each worker

kwargscluster:

Additional parameters to be passed to the cluster creation routine

Returns:
client : dask.distributed.client.Client

Client

cluster :

Cluster

Raises:
NotImplementedError

If hardware is not single, ssh, or pbs