def to_number(self, value):
        """
        Transform categorical value to the ordinal. Raises ValueError if value is not in self.value_list
        """
        try:
            return list(self.value_list).index(value)
        except __HOLE__ as e:
            if self.map_missing_to:
                return self.map_missing_to
            else:
                raise e
dataset/ETHPy150Open alex-pirozhenko/sklearn-pmml/sklearn_pmml/convert/features.py/CategoricalFeature.to_number