This transform iterates over a dataset to construct key to value mapping. These mappings are used by other transformers like OneHotVectorizer, etc. This is a trainable transform and it should have a checkpoint to see if the user has triggered cancellation.