def process_return(task: Task) -> Tuple[Union[int, str], ProfileResult]:
    """Generate profile result from a profiling task

    Parameters
    ----------
    task : Task
        A profiling task

    Returns
    -------
    Tuple[Union[int, str], ProfileResult]
        Tuple of task idx (usually the algorithm name/id) and profiling result
    """
    return (task._idx, task._ret)
Generate profile result from a profiling task

Parameters
----------
task : Task
A profiling task

Returns
-------
Tuple[Union[int, str], ProfileResult]
Tuple of task idx (usually the algorithm name/id) and profiling result
python/aitemplate/backend/profiler_runner.py