class_docstr: Base class for AdaBoost estimators.
  
  Warning: This class should not be used directly. Use derived classes
  instead.
class_docstr_tok: ["Base","class","for","AdaBoost","estimators",".","Warning",":","This","class","should","not","be","used","directly",".","Use","derived","classes","instead","."]
docstr: Implement a single boost.
  
  Warning: This method needs to be overridden by subclasses.
  
  Parameters
  ----------
  iboost : int
      The index of the current boost iteration.
  
  X : {array-like, sparse matrix} of shape (n_samples, n_features)
      The training input samples. Sparse matrix can be CSC, CSR, COO,
      DOK, or LIL. COO, DOK, and LIL are converted to CSR.
  
  y : array-like of shape (n_samples,)
      The target values (class labels).
  
  sample_weight : array-like of shape (n_samples,)
      The current sample weights.
  
  random_state : RandomState
      The current random number generator
  
  Returns
  -------
  sample_weight : array-like of shape (n_samples,) or None
      The reweighted sample weights.
      If None then boosting has terminated early.
  
  estimator_weight : float
      The weight for the current boost.
      If None then boosting has terminated early.
  
  error : float
      The classification error for the current boost.
      If None then boosting has terminated early.
docstr_tok: ["Implement","a","single","boost",".","Warning",":","This","method","needs","to","be","overridden","by","subclasses",".","Parameters","--","--","--","--","--","iboost",":","int","The","index","of","the","current","boost","iteration",".","X",":","{","array-like",",","sparse","matrix","}","of","shape","(","n_samples",",","n_features",")","The","training","input","samples",".","Sparse","matrix","can","be","CSC",",","CSR",",","COO",",","DOK",",","or","LIL",".","COO",",","DOK",",","and","LIL","are","converted","to","CSR",".","y",":","array-like","of","shape","(","n_samples",",",")","The","target","values","(","class","labels",")",".","sample_weight",":","array-like","of","shape","(","n_samples",",",")","The","current","sample","weights",".","random_state",":","RandomState","The","current","random","number","generator","Returns","--","--","--","-","sample_weight",":","array-like","of","shape","(","n_samples",",",")","or","None","The","reweighted","sample","weights",".","If","None","then","boosting","has","terminated","early",".","estimator_weight",":","float","The","weight","for","the","current","boost",".","If","None","then","boosting","has","terminated","early",".","error",":","float","The","classification","error","for","the","current","boost",".","If","None","then","boosting","has","terminated","early","."]
code: def _boost(self, iboost, X, y, sample_weight, random_state):
      """Implement a single boost.
  
      Warning: This method needs to be overridden by subclasses.
  
      Parameters
      ----------
      iboost : int
          The index of the current boost iteration.
  
      X : {array-like, sparse matrix} of shape (n_samples, n_features)
          The training input samples. Sparse matrix can be CSC, CSR, COO,
          DOK, or LIL. COO, DOK, and LIL are converted to CSR.
  
      y : array-like of shape (n_samples,)
          The target values (class labels).
  
      sample_weight : array-like of shape (n_samples,)
          The current sample weights.
  
      random_state : RandomState
          The current random number generator
  
      Returns
      -------
      sample_weight : array-like of shape (n_samples,) or None
          The reweighted sample weights.
          If None then boosting has terminated early.
  
      estimator_weight : float
          The weight for the current boost.
          If None then boosting has terminated early.
  
      error : float
          The classification error for the current boost.
          If None then boosting has terminated early.
      """
      pass
  
imports: import warnings
  from abc import ABCMeta, abstractmethod
  from numbers import Integral, Real
  import numpy
  from scipy.special import xlogy
  from ..base import ClassifierMixin, RegressorMixin, _fit_context, is_classifier, is_regressor
  from ..metrics import accuracy_score, r2_score
  from ..tree import DecisionTreeClassifier, DecisionTreeRegressor
  from ..utils import _safe_indexing, check_random_state
  from ..utils._param_validation import HasMethods, Interval, StrOptions
  from ..utils.extmath import softmax, stable_cumsum
  from ..utils.validation import _check_sample_weight, _num_samples, check_is_fitted, has_fit_parameter
  from ._base import BaseEnsemble
label_desc: Use image node_id 4 for calling the BaseWeightBoosting obj's underlying member method code with example usage: obj._boost(iboost, X, y, sample_weight, random_state) without return types