code: def test_estimate_competence2(
      index, expected, example_estimate_competence
  ):
      (
          _,
          _,
          neighbors,
          distances,
          dsel_processed,
          _,
      ) = example_estimate_competence
  
      mcb_test = MCB()
      mcb_test.n_classifiers_ = 3
      mcb_test.DSEL_processed_ = dsel_processed
  
      neighbors = neighbors[index, :].reshape(1, -1)
      distances = distances[index, :].reshape(1, -1)
      # Only changing the pre-processed BKS to see if the filter works.
      mcb_test.BKS_DSEL_ = bks_dsel_ex2
  
      predictions = np.array([[0, 1, 0]])
  
      competences = mcb_test.estimate_competence(
          neighbors,
          distances=distances,
          predictions=np.atleast_2d(predictions),
      )
      assert np.isclose(competences, expected).all()
  
file_path: DESlib/deslib/tests/dcs/test_mcb.py
imports: import numpy
  import pytest
  from sklearn.linear_model import Perceptron
  from sklearn.utils.estimator_checks import check_estimator
  from deslib.dcs.mcb import MCB
label_desc: Use image node_id 4 for calling a global function with example usage: test_estimate_competence2(index, expected, example_estimate_competence) without return types