MCPcopy Index your code
hub / github.com/apache/tvm / submit

Method submit

python/tvm/support/popen_pool.py:443–464  ·  view source on GitHub ↗

Submit a new function job to the pool Parameters ---------- fn : function The function to be invoked. args : list Positional argument. kwargs : dict Keyword arguments Returns ------- future : conc

(self, fn, *args, **kwargs)

Source from the content-addressed store, hash-verified

441 return MapResult(status=StatusKind.EXCEPTION, value=exception)
442
443 def submit(self, fn, *args, **kwargs) -> concurrent.futures.Future:
444 """Submit a new function job to the pool
445
446 Parameters
447 ----------
448 fn : function
449 The function to be invoked.
450
451 args : list
452 Positional argument.
453
454 kwargs : dict
455 Keyword arguments
456
457 Returns
458 -------
459 future : concurrent.futures.Future
460 A future that can be used to access the result.
461 """
462 # pylint: disable=unnecessary-lambda
463 worker = lambda *args: self._worker_run(*args)
464 return self._threadpool.submit(worker, fn, args, kwargs)
465
466 def map_with_error_catching(self, fn, iterator):
467 """Same as map, but catches exceptions and return them instead.

Callers 13

_sanity_checkMethod · 0.95
test_popen_pool_executorFunction · 0.95
runMethod · 0.80
_sanity_checkMethod · 0.80
runMethod · 0.80
_sanity_checkMethod · 0.80
clearMethod · 0.80
drawMethod · 0.80
flushCommandsMethod · 0.80
deviceCopyFromGPUMethod · 0.80

Calls 1

_worker_runMethod · 0.95