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


Creates an extractor for extracting slice keys.

The incoming Extracts must contain features stored under tfma.FEATURES_KEY and optionally under tfma.TRANSFORMED_FEATURES.

The extractor's PTransform yields a copy of the Extracts input with an additional extract pointing at the list of SliceKeyType values keyed by tfma.SLICE_KEY_TYPES_KEY. If materialize is True then a materialized version of the slice keys will be added under the key tfma.MATERIALZED_SLICE_KEYS_KEY.

slice_spec Deprecated (use EvalConfig).
eval_config Optional EvalConfig containing slicing_specs specifying the slices to slice the data into. If slicing_specs are empty, defaults to overall slice.
materialize True to add MaterializedColumn entries for the slice keys.

Extractor for slice keys.