keras/src/layers/preprocessing/category_encoding.py/CategoryEncoding/compute_output_spec
class CategoryEncoding:    def compute_output_spec(self, inputs, count_weights=None):
        output_shape = self.compute_output_shape(inputs.shape)
        return KerasTensor(
            output_shape, dtype=self.compute_dtype, sparse=self.sparse
        )