mirror of https://github.com/tqdm/tqdm.git
parent
8c35d4228c
commit
98f7289675
|
@ -58,7 +58,7 @@ def _executor_map(PoolExecutor, fn, *iterables, **tqdm_kwargs):
|
||||||
"""
|
"""
|
||||||
kwargs = tqdm_kwargs.copy()
|
kwargs = tqdm_kwargs.copy()
|
||||||
if "total" not in kwargs:
|
if "total" not in kwargs:
|
||||||
kwargs["total"] = len(iterables[0])
|
kwargs["total"] = length_hint(iterables[0])
|
||||||
tqdm_class = kwargs.pop("tqdm_class", tqdm_auto)
|
tqdm_class = kwargs.pop("tqdm_class", tqdm_auto)
|
||||||
max_workers = kwargs.pop("max_workers", min(32, cpu_count() + 4))
|
max_workers = kwargs.pop("max_workers", min(32, cpu_count() + 4))
|
||||||
chunksize = kwargs.pop("chunksize", 1)
|
chunksize = kwargs.pop("chunksize", 1)
|
||||||
|
|
Loading…
Reference in New Issue