class_docstr: An ensembler using the voting method.
  
  Parameters
  ----------
  ensemble_size : int
      The number of base models selected by the voter. These selected models can be redundant. Default as 10.
class_docstr_tok: ["An","ensembler","using","the","voting","method",".","Parameters","--","--","--","--","--","ensemble_size",":","int","The","number","of","base","models","selected","by","the","voter",".","These","selected","models","can","be","redundant",".","Default","as","10","."]
docstr: Ensemble the predictions of base models.
  
  Parameters
  ----------
  predictions : a list of np.ndarray
      Predictions of base learners (corresponding to the elements in identifiers).
  identifiers : a list of str
      The names of base models.
  
  Returns
  -------
  np.ndarray
      The ensembled predictions.
docstr_tok: ["Ensemble","the","predictions","of","base","models",".","Parameters","--","--","--","--","--","predictions",":","a","list","of","np.ndarray","Predictions","of","base","learners","(","corresponding","to","the","elements","in","identifiers",")",".","identifiers",":","a","list","of","str","The","names","of","base","models",".","Returns","--","--","--","-","np.ndarray","The","ensembled","predictions","."]
code: def ensemble(self, predictions, identifiers, *args, **kwargs):
      """
      Ensemble the predictions of base models.
  
      Parameters
      ----------
      predictions : a list of np.ndarray
          Predictions of base learners (corresponding to the elements in identifiers).
      identifiers : a list of str
          The names of base models.
  
      Returns
      -------
      np.ndarray
          The ensembled predictions.
      """
  
      weights = np.zeros([len(predictions)])
      for idx, model in enumerate(identifiers):
          weights[idx] = self.model_to_weight[model]
      weights = weights / np.sum(weights)
  
      return np.average(predictions, axis=0, weights=weights)
  
file_path: AutoGL/autogl/module/ensemble/voting.py
imports: from collections import Counter
  import numpy
  from .base import BaseEnsembler
  from .None import register_ensembler
  from ...utils import get_logger
label_desc: Use image node_id 3 for calling the Voting obj's underlying member method code with example usage: obj.ensemble(predictions, identifiers) and returns: np