original_docstring: 
          Predict cumulative class probabilities for X.
          
          NOTE: This function should be used with care, as it returns the binary 
          classifier ensemble component probabilities:
              - e.g. for y in {1,2,3,4} the returned probabilities are [P(y>1), P(y>2), P(y>3)]
      
          The predicted class probabilities of an input sample are computed as
          the mean predicted class probabilities of the trees in the forest.
          The class probability of a single tree is the fraction of samples of
          the same class in a leaf.
          Parameters
          ----------
          X : {array-like, sparse matrix} of shape (n_samples, n_features)
              The input samples. Internally, its dtype will be converted to
              ``dtype=np.float32``. If a sparse matrix is provided, it will be
              converted into a sparse ``csr_matrix``.
          Returns
          -------
          p : ndarray of shape (n_samples, n_classes), or a list of n_outputs
              such arrays if n_outputs > 1.
              The class probabilities of the input samples. The order of the
              classes corresponds to that in the attribute :term:`classes_`.
          
docstring: Predict cumulative class probabilities for X.
  NOTE: This function should be used with care, as it returns the binary
  classifier ensemble component probabilities:
  e.g.
  
  The predicted class probabilities of an input sample are computed as
  the mean predicted class probabilities of the trees in the forest.
  The class probability of a single tree is the fraction of samples of
  the same class in a leaf.
  Parameters
  
  X : {array-like, sparse matrix} of shape (n_samples, n_features)
  The input samples. Internally, its dtype will be converted to
  ``dtype=np.float32``. If a sparse matrix is provided, it will be
  converted into a sparse ``csr_matrix``.
  Returns
  
  p : ndarray of shape (n_samples, n_classes), or a list of n_outputs
  such arrays if n_outputs > 1.
  The class probabilities of the input samples. The order of the
  classes corresponds to that in the attribute :term:`classes_`.
docstring_tokens: Predict cumulative class probabilities for X . NOTE : This function should be used with care as it returns the binary classifier ensemble component probabilities : e . g . The predicted class probabilities of an input sample are computed as the mean predicted class probabilities of the trees in the forest . The class probability of a single tree is the fraction of samples of the same class in a leaf . Parameters X : { array - like sparse matrix } of shape ( n_samples n_features ) The input samples . Internally its dtype will be converted to ` ` dtype = np . float32 ` ` . If a sparse matrix is provided it will be converted into a sparse ` ` csr_matrix ` ` . Returns p : ndarray of shape ( n_samples n_classes ) or a list of n_outputs such arrays if n_outputs > 1 . The class probabilities of the input samples . The order of the classes corresponds to that in the attribute : term : ` classes_ ` .
code: def predict_cum_proba(self, X):
          """
          Predict cumulative class probabilities for X.
          
          NOTE: This function should be used with care, as it returns the binary 
          classifier ensemble component probabilities:
              - e.g. for y in {1,2,3,4} the returned probabilities are [P(y>1), P(y>2), P(y>3)]
      
          The predicted class probabilities of an input sample are computed as
          the mean predicted class probabilities of the trees in the forest.
          The class probability of a single tree is the fraction of samples of
          the same class in a leaf.
          Parameters
          ----------
          X : {array-like, sparse matrix} of shape (n_samples, n_features)
              The input samples. Internally, its dtype will be converted to
              ``dtype=np.float32``. If a sparse matrix is provided, it will be
              converted into a sparse ``csr_matrix``.
          Returns
          -------
          p : ndarray of shape (n_samples, n_classes), or a list of n_outputs
              such arrays if n_outputs > 1.
              The class probabilities of the input samples. The order of the
              classes corresponds to that in the attribute :term:`classes_`.
          """
          # check_is_fitted(self)
          # Check data
          X = self._validate_X_predict(X)
  
          # Assign chunk of trees to jobs
          n_jobs, _, _ = _partition_estimators(self.n_estimators, self.n_jobs)
  
          # avoid storing the output of every estimator by summing them here
          all_proba = [np.zeros((X.shape[0], j-1), dtype=np.float64)
                       for j in np.atleast_1d(self.n_classes_)]
          lock = threading.Lock()
          # for e in self.estimators_:
          #     print((e.predict_cum_proba(X)).shape[1])
          # print(all_proba)
          Parallel(n_jobs=n_jobs, verbose=self.verbose,
                   **_joblib_parallel_args(require="sharedmem"))(
              delayed(_accumulate_prediction)(e.predict_cum_proba, X, all_proba,
                                              lock)
              for e in self.estimators_)
  
          for proba in all_proba:
              proba /= len(self.estimators_)
  
          if len(all_proba) == 1:
              return all_proba[0]
          else:
              return all_proba
code_tokens: def predict_cum_proba ( self , X ) : X = self . _validate_X_predict ( X ) n_jobs , _ , _ = _partition_estimators ( self . n_estimators , self . n_jobs ) all_proba = [ np . zeros ( ( X . shape [ 0 ] , j - 1 ) , dtype = np . float64 ) for j in np . atleast_1d ( self . n_classes_ ) ] lock = threading . Lock ( ) Parallel ( n_jobs = n_jobs , verbose = self . verbose , ** _joblib_parallel_args ( require = "sharedmem" ) ) ( delayed ( _accumulate_prediction ) ( e . predict_cum_proba , X , all_proba , lock ) for e in self . estimators_ ) for proba in all_proba : proba /= len ( self . estimators_ ) if len ( all_proba ) == 1 : return all_proba [ 0 ] else : return all_proba
short_docstring: Predict cumulative class probabilities for X.
short_docstring_tokens: Predict cumulative class probabilities for X .
comment: """
          Predict cumulative class probabilities for X.
          
          NOTE: This function should be used with care, as it returns the binary 
          classifier ensemble component probabilities:
              - e.g. for y in {1,2,3,4} the returned probabilities are [P(y>1), P(y>2), P(y>3)]
      
          The predicted class probabilities of an input sample are computed as
          the mean predicted class probabilities of the trees in the forest.
          The class probability of a single tree is the fraction of samples of
          the same class in a leaf.
          Parameters
          ----------
          X : {array-like, sparse matrix} of shape (n_samples, n_features)
              The input samples. Internally, its dtype will be converted to
              ``dtype=np.float32``. If a sparse matrix is provided, it will be
              converted into a sparse ``csr_matrix``.
          Returns
          -------
          p : ndarray of shape (n_samples, n_classes), or a list of n_outputs
              such arrays if n_outputs > 1.
              The class probabilities of the input samples. The order of the
              classes corresponds to that in the attribute :term:`classes_`.
          """$SEP$# check_is_fitted(self)$SEP$# Check data$SEP$# Assign chunk of trees to jobs$SEP$# avoid storing the output of every estimator by summing them here$SEP$# for e in self.estimators_:$SEP$#     print((e.predict_cum_proba(X)).shape[1])$SEP$# print(all_proba)