![]() |
Filters dict by input names.
tfma.model_util.filter_by_input_names(
d: Dict[Text, Any],
input_names: List[Text]
) -> Optional[Dict[Text, Any]]
In case we don't find the specified input name in the dict and there exists only one input name, we assume we are feeding serialized examples to the model and return None.
Args | |
---|---|
d
|
Dict to filter. |
input_names
|
List of input names. |
Returns | |
---|---|
Dict with keys matching input_names. |
Raises | |
---|---|
RuntimeError
|
When the specified input name cannot be found. |