def METHOD_NAME(self, X):
    for column in self._columns:
        if PreprocessingUtils.get_type(X[column]) != PreprocessingUtils.CATEGORICAL:
            # no need to convert, already a number
            continue
        # limit categories - it is needed when doing one hot encoding
        # this code is also used in predict.py file
        # and transform_utils.py
        # TODO it needs refactoring !!!
        too_much_categories = len(np.unique(list(X[column].values))) > 200
        lbl = None
        if (
            self._convert_method == PreprocessingCategorical.CONVERT_ONE_HOT
            and not too_much_categories
        ):
            lbl = LabelBinarizer()
            lbl.fit(X, column)
        else:
            lbl = LabelEncoder()
            lbl.fit(X[column])
        if lbl is not None:
            self._convert_params[column] = lbl.to_json()