imap(func, iterable[, chunksize])
A lazier version of map()
.
The chunksize argument is the same as the one used by the map()
method. For very long iterables using a large value for chunksize can make the job complete much faster than using the default value of 1
.
Also if chunksize is 1
then the next()
method of the iterator returned by the imap()
method has an optional timeout parameter: next(timeout)
will raise multiprocessing.TimeoutError
if the result cannot be returned within timeout seconds.
Please login to continue.