code: def test_estimate_competence_batch(
      example_estimate_competence, create_pool_classifiers
  ):
      (
          X,
          y,
          neighbors,
          distances,
          dsel_processed,
          _,
      ) = example_estimate_competence
  
      expected = np.array(
          [
              [0.57142857, 0.4285714, 0.57142857],
              [0.71428571, 0.2857142, 0.71428571],
              [0.2857142, 0.71428571, 0.2857142],
          ]
      )
  
      des_p_test = DESP(create_pool_classifiers)
      des_p_test.fit(X, y)
      competences = des_p_test.estimate_competence(neighbors, distances)
      assert np.allclose(competences, expected, atol=0.01)
  
file_path: DESlib/deslib/tests/des/test_desp.py
imports: import numpy
  from sklearn.linear_model import Perceptron
  from sklearn.utils.estimator_checks import check_estimator
  from deslib.des.des_p import DESP
label_desc: Use image node_id 2 for calling a global function with example usage: test_estimate_competence_batch(example_estimate_competence, create_pool_classifiers) without return types