class_docstr: This class implements the classification task.
  
  It implements a pipeline, which includes one preprocessing step and one
  classification algorithm. It can render a search space including all known
  classification and preprocessing algorithms.
  
  Contrary to the sklearn API it is not possible to enumerate the
  possible parameters in the __init__ function because we only know the
  available classifiers at runtime. For this reason the user must
  specifiy the parameters by passing an instance of
  ConfigSpace.configuration_space.Configuration.
  
  Parameters
  ----------
  config : ConfigSpace.configuration_space.Configuration
      The configuration to evaluate.
  
  random_state : Optional[int | RandomState]
      If int, random_state is the seed used by the random number generator;
      If RandomState instance, random_state is the random number generator;
      If None, the random number generator is the RandomState instance
      used by `np.random`.
  
  Attributes
  ----------
  _estimator : The underlying scikit-learn classification model. This
      variable is assigned after a call to the
      :meth:`autosklearn.pipeline.classification.SimpleClassificationPipeline
      .fit` method.
  
  _preprocessor : The underlying scikit-learn preprocessing algorithm. This
      variable is only assigned if a preprocessor is specified and
      after a call to the
      :meth:`autosklearn.pipeline.classification.SimpleClassificationPipeline
      .fit` method.
  
  See also
  --------
  
  References
  ----------
  
  Examples
  --------
docstr: Create the hyperparameter configuration space.
  
  Parameters
  ----------
  feat_type : dict, maps columns to there datatypes
  
  include : dict (optional, default=None)
  
  Returns
  -------
  cs : ConfigSpace.configuration_space.Configuration
      The configuration space describing the SimpleRegressionClassifier.
docstr_tok: ["Create","the","hyperparameter","configuration","space",".","Parameters","--","--","--","--","--","feat_type",":","dict",",","maps","columns","to","there","datatypes","include",":","dict","(","optional",",","default=None",")","Returns","--","--","--","-","cs",":","ConfigSpace.configuration_space.Configuration","The","configuration","space","describing","the","SimpleRegressionClassifier","."]
code: def _get_hyperparameter_search_space(
      self,
      feat_type: Optional[FEAT_TYPE_TYPE] = None,
      include=None,
      exclude=None,
      dataset_properties=None,
  ):
      """Create the hyperparameter configuration space.
  
      Parameters
      ----------
      feat_type : dict, maps columns to there datatypes
  
      include : dict (optional, default=None)
  
      Returns
      -------
      cs : ConfigSpace.configuration_space.Configuration
          The configuration space describing the SimpleRegressionClassifier.
      """
      cs = ConfigurationSpace()
  
      if dataset_properties is None or not isinstance(
          dataset_properties, dict
      ):
          dataset_properties = dict()
      if "target_type" not in dataset_properties:
          dataset_properties["target_type"] = "classification"
      if dataset_properties["target_type"] != "classification":
          dataset_properties["target_type"] = "classification"
  
      if "sparse" not in dataset_properties:
          # This dataset is probably dense
          dataset_properties["sparse"] = False
  
      cs = self._get_base_search_space(
          cs=cs,
          feat_type=feat_type,
          dataset_properties=dataset_properties,
          exclude=exclude,
          include=include,
          pipeline=self.steps,
      )
  
      classifiers = cs.get_hyperparameter(
          "classifier:__choice__"
      ).choices
      preprocessors = cs.get_hyperparameter(
          "feature_preprocessor:__choice__"
      ).choices
      available_classifiers = (
          self._final_estimator.get_available_components(
              dataset_properties
          )
      )
  
      possible_default_classifier = copy.copy(
          list(available_classifiers.keys())
      )
      default = cs.get_hyperparameter(
          "classifier:__choice__"
      ).default_value
      del possible_default_classifier[
          possible_default_classifier.index(default)
      ]
  
      # A classifier which can handle sparse data after the densifier is
      # forbidden for memory issues
      for key in classifiers:
          if (
              SPARSE
              in available_classifiers[key].get_properties()["input"]
          ):
              if "densifier" in preprocessors:
                  while True:
                      try:
                          forb_cls = ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "classifier:__choice__"
                              ),
                              key,
                          )
                          forb_fpp = ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "feature_preprocessor:__choice__"
                              ),
                              "densifier",
                          )
                          cs.add_forbidden_clause(
                              ForbiddenAndConjunction(
                                  forb_cls, forb_fpp
                              )
                          )
                          # Success
                          break
                      except ValueError:
                          # Change the default and try again
                          try:
                              default = (
                                  possible_default_classifier.pop()
                              )
                          except IndexError:
                              raise ValueError(
                                  "Cannot find a legal default configuration."
                              )
                          cs.get_hyperparameter(
                              "classifier:__choice__"
                          ).default_value = default
  
      # which would take too long
      # Combinations of non-linear models with feature learning:
      classifiers_ = [
          "adaboost",
          "decision_tree",
          "extra_trees",
          "gradient_boosting",
          "k_nearest_neighbors",
          "libsvm_svc",
          "mlp",
          "random_forest",
          "gaussian_nb",
      ]
      feature_learning = [
          "kernel_pca",
          "kitchen_sinks",
          "nystroem_sampler",
      ]
  
      for c, f in product(classifiers_, feature_learning):
          if c not in classifiers:
              continue
          if f not in preprocessors:
              continue
          while True:
              try:
                  cs.add_forbidden_clause(
                      ForbiddenAndConjunction(
                          ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "classifier:__choice__"
                              ),
                              c,
                          ),
                          ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "feature_preprocessor:__choice__"
                              ),
                              f,
                          ),
                      )
                  )
                  break
              except KeyError:
                  break
              except ValueError:
                  # Change the default and try again
                  try:
                      default = possible_default_classifier.pop()
                  except IndexError:
                      raise ValueError(
                          "Cannot find a legal default configuration."
                      )
                  cs.get_hyperparameter(
                      "classifier:__choice__"
                  ).default_value = default
  
      # Won't work
      # Multinomial NB etc don't use with features learning, pca etc
      classifiers_ = ["multinomial_nb"]
      preproc_with_negative_X = [
          "kitchen_sinks",
          "pca",
          "truncatedSVD",
          "fast_ica",
          "kernel_pca",
          "nystroem_sampler",
      ]
  
      for c, f in product(classifiers_, preproc_with_negative_X):
          if c not in classifiers:
              continue
          if f not in preprocessors:
              continue
          while True:
              try:
                  cs.add_forbidden_clause(
                      ForbiddenAndConjunction(
                          ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "feature_preprocessor:__choice__"
                              ),
                              f,
                          ),
                          ForbiddenEqualsClause(
                              cs.get_hyperparameter(
                                  "classifier:__choice__"
                              ),
                              c,
                          ),
                      )
                  )
                  break
              except KeyError:
                  break
              except ValueError:
                  # Change the default and try again
                  try:
                      default = possible_default_classifier.pop()
                  except IndexError:
                      raise ValueError(
                          "Cannot find a legal default configuration."
                      )
                  cs.get_hyperparameter(
                      "classifier:__choice__"
                  ).default_value = default
  
      self.configuration_space = cs
      self.dataset_properties = dataset_properties
      return cs
  
imports: from typing import Optional, Union
  import copy
  from itertools import product
  import numpy
  from ConfigSpace.configuration_space import Configuration, ConfigurationSpace
  from ConfigSpace.forbidden import ForbiddenAndConjunction, ForbiddenEqualsClause
  from sklearn.base import ClassifierMixin
  from autosklearn.askl_typing import FEAT_TYPE_TYPE
  from autosklearn.pipeline.base import BasePipeline
  from autosklearn.pipeline.components.classification import ClassifierChoice
  from autosklearn.pipeline.components.data_preprocessing import DataPreprocessorChoice
  from autosklearn.pipeline.components.data_preprocessing.balancing.balancing import Balancing
  from autosklearn.pipeline.components.feature_preprocessing import FeaturePreprocessorChoice
  from autosklearn.pipeline.constants import SPARSE
label_desc: Use image node_id 4 for calling the SimpleClassificationPipeline obj's underlying member method code with example usage: obj._get_hyperparameter_search_space(feat_type, include, exclude, dataset_properties) and returns: cs