"""Returns a local Dask client with the given parameters, see the dask documentation for details: https://docs.dask.org/en/latest/how-to/deploy-dask/single-distributed.html?highlight=localcluster#localcluster
Parameters
----------
n_workers: int or None
The number of workers (processes) to use; if `None`, take as many processors as we have on the system
parallel: int or None
The number of workers (processes or threads) to use; if `None`, take as many processors as we have on the system
processes: boolean
Shall the dask client start processes (True, recommended) or threads (False). Note that threads in pyton do not run in parallel
threads_per_worker: int
How many threads (not processes) per worker to you allow?
Shall the dask client start processes (True, recommended) or threads (False). Note that threads in pure pyton do not run in parallel, see: https://www.quantstart.com/articles/Parallelising-Python-with-Threading-and-Multiprocessing/