class_docstr: Abstract method that always selects the base classifier that predicts
  the correct label if such classifier exists. This method is often used to
  measure the upper-limit performance that can be achieved by a dynamic
  classifier selection technique. It is used as a benchmark by several
  dynamic selection algorithms.
  
  Parameters
  ----------
  pool_classifiers : list of classifiers (Default = None)
      The generated_pool of classifiers trained for the corresponding
      classification problem. Each base classifiers should support the method
      "predict". If None, then the pool of classifiers is a bagging
      classifier.
  
  random_state : int, RandomState instance or None, optional (default=None)
      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`.
  
  n_jobs : int, default=-1
      The number of parallel jobs to run. None means 1 unless in
      a joblib.parallel_backend context. -1 means using all processors.
      Doesn’t affect fit method.
  
  References
  ----------
  Kuncheva, Ludmila I. "A theoretical study on six classifier fusion
  strategies." IEEE Transactions on Pattern Analysis & Machine Intelligence,
  (2002): 281-286.
  
  R. M. O. Cruz, R. Sabourin, and G. D. Cavalcanti, “Dynamic classifier
  selection: Recent advances and perspectives,”
  Information Fusion, vol. 41, pp. 195 – 216, 2018.
docstr: Estimates the posterior probabilities for each class for each sample
  in X.
  
  Note that as the Oracle is the ideal classifier selection, the
  classifier that estimate the highest probability for the correct class
  is the selected one.
  
  Parameters
  ----------
  X : array of shape (n_samples, n_features)
      The data to be classified.
  
  y : array of shape (n_samples)
      Class labels of each sample in X.
  
  Returns
  -------
  probas : array of shape (n_samples, n_classes)
      Posterior probabilities estimates for each class.
docstr_tok: ["Estimates","the","posterior","probabilities","for","each","class","for","each","sample","in","X",".","Note","that","as","the","Oracle","is","the","ideal","classifier","selection",",","the","classifier","that","estimate","the","highest","probability","for","the","correct","class","is","the","selected","one",".","Parameters","--","--","--","--","--","X",":","array","of","shape","(","n_samples",",","n_features",")","The","data","to","be","classified",".","y",":","array","of","shape","(","n_samples",")","Class","labels","of","each","sample","in","X",".","Returns","--","--","--","-","probas",":","array","of","shape","(","n_samples",",","n_classes",")","Posterior","probabilities","estimates","for","each","class","."]
code: def predict_proba(self, X, y):
      """Estimates the posterior probabilities for each class for each sample
      in X.
  
      Note that as the Oracle is the ideal classifier selection, the
      classifier that estimate the highest probability for the correct class
      is the selected one.
  
      Parameters
      ----------
      X : array of shape (n_samples, n_features)
          The data to be classified.
  
      y : array of shape (n_samples)
          Class labels of each sample in X.
  
      Returns
      -------
      probas : array of shape (n_samples, n_classes)
          Posterior probabilities estimates for each class.
  
      """
      X = check_array(X)
      y = self.enc_.transform(y)
  
      probas = [
          clf.predict_proba(X[:, self.estimator_features_[idx]])
          for idx, clf in enumerate(self.pool_classifiers_)
      ]
      probas = np.array(probas).transpose((1, 0, 2))
      best_probas_ids = np.argmax(
          probas[np.arange(y.size), :, y], axis=1
      )
      return probas[np.arange(y.size), best_probas_ids, :]
  
file_path: DESlib/deslib/static/oracle.py
imports: import numpy
  from sklearn.utils.validation import check_X_y, check_array
  from deslib.static.base import BaseStaticEnsemble
label_desc: Use image node_id 4 for calling the Oracle obj's underlying member method code with example usage: obj.predict_proba(X, y) and returns: probas