ML Community Day is November 9! Join us for updates from TensorFlow, JAX, and more Learn more


Gets feature values associated with given model spec fields from extracts.

model_specs List of model specs from EvalConfig.
field Name of field used to determine the feature(s) to extract. This should be an attribute on the ModelSpec such as "label_key", "example_weight_key", or "prediction_key".
multi_output_field Optional name of field used to store multi-output versions of the features. This should be an attribute on the ModelSpec such as "label_keys", "example_weight_keys", or "prediction_keys". This field is only used if a value at field is not found.
batched_extracts Extracts containing batched features keyed by tfma.FEATURES_KEY and optionally tfma.TRANSFORMED_FEATURES_KEY.
allow_missing True if the feature may be missing (in which case None will be used as the value).

Feature values stored at given key (or feature values stored at each output keyed by output name if field containing map of feature keys was used). If multiple models are used the value(s) will be stored in a dict keyed by model name. If no values are found and allow_missing is False then None will be returned.