tasks.utils package
Submodules
tasks.utils.outputs module
- class OutputKeys(value)[source]
 Bases:
StrEnumEnum class for the keys of the output dictionary.
- LOG = 'logs'
 
- LOSS = 'loss'
 
- PREDICTION = 'pred'
 
- TARGET = 'target'
 
- reduce_dict(input_dict: Dict, key_list: List) Dict[source]
 Reduce the input dictionary to only contain the keys in the key_list.
- Parameters:
 input_dict (Dict) – The dictionary to reduce
key_list (List) – List of keys to keep
- Returns:
 The dictionary input_dict with only the keys in the key_list
- Return type:
 Dict
tasks.utils.task_utils module
- get_callable_dict(fn: Union[Callable, Mapping, Sequence]) Union[Dict, Mapping][source]
 Creates a dictionary with the name of the callable as key and the callable as value.
- Parameters:
 fn (Union[Callable, Mapping, Sequence]) – Callable, sequence or mapping we want to convert to a dictionary
- Returns:
 A dictionary with the name of the callable as key and the callable as value
- Return type:
 Union[Dict, Mapping]