class_docstr: Base class for a dynamic classifier selection (dcs) and
     dynamic ensemble selection (des) methods.
  
  All DCS and DES techniques should inherit from this class.
  
  Warning: This class should not be used directly.
  Use derived classes instead.
docstr: Get the predictions of each base classifier in the pool for all
      samples in X.
  
  Parameters
  ----------
  X : array of shape (n_samples, n_features)
      The test examples.
  
  Returns
  -------
  predictions : array of shape (n_samples, n_classifiers)
                The predictions of each base classifier for all samples
                in X.
docstr_tok: ["Get","the","predictions","of","each","base","classifier","in","the","pool","for","all","samples","in","X.","Parameters","--","--","--","--","--","X",":","array","of","shape","(","n_samples",",","n_features",")","The","test","examples",".","Returns","--","--","--","-","predictions",":","array","of","shape","(","n_samples",",","n_classifiers",")","The","predictions","of","each","base","classifier","for","all","samples","in","X","."]
code: def _predict_base(self, X):
      """Get the predictions of each base classifier in the pool for all
          samples in X.
  
      Parameters
      ----------
      X : array of shape (n_samples, n_features)
          The test examples.
  
      Returns
      -------
      predictions : array of shape (n_samples, n_classifiers)
                    The predictions of each base classifier for all samples
                    in X.
      """
      predictions = np.zeros(
          (X.shape[0], self.n_classifiers_), dtype=np.intp
      )
  
      for index, clf in enumerate(self.pool_classifiers_):
          labels = clf.predict(X[:, self.estimator_features_[index]])
          predictions[:, index] = self._encode_base_labels(labels)
      return predictions
  
imports: import functools
  import math
  import warnings
  from abc import abstractmethod, ABCMeta
  import numpy
  from scipy.stats import mode
  from sklearn.base import BaseEstimator, ClassifierMixin
  from sklearn.ensemble import BaseEnsemble, BaggingClassifier
  from sklearn.model_selection import train_test_split
  from sklearn.neighbors import KNeighborsClassifier
  from sklearn.preprocessing import LabelEncoder, normalize
  from sklearn.utils.validation import check_X_y, check_is_fitted, check_array, check_random_state
  from deslib.util import KNNE
  from deslib.util import faiss_knn_wrapper
  from deslib.util.dfp import frienemy_pruning_preprocessed
  from deslib.util.instance_hardness import hardness_region_competence
label_desc: Use image node_id 28 for calling the BaseDS obj's underlying member method code with example usage: obj._predict_base(X) and returns: predictions