TL;DR: how to access the maximal number of workers accessible to dask.distributed.client, which would include the workers that aren't started yet, and would work with the adaptive as well as non-adaptive scaling strategy?
I develop a library for adaptive parallel execution of functions, which plans ahead what points to execute. For that we need to know how many workers can be accessed in parallel, and we use client.ncores() function.
This approach is, however, problematic, for several reasons:
- The workers need to be running in the first place because
ncoresonly tells about what is happening now. - If the cluster has adaptive scaling, we're interested in the maximal number of workers that we can get rather than in the current one.
Therefore I would like to know if there's a programmatic way to inspect the client and determine how many workers a dask cluster can acquire.