code: def test_duplicates(
      self, desired_class, sample_custom_query_4, total_CFs
  ):
      self.exp._generate_counterfactuals(
          query_instance=sample_custom_query_4,
          total_CFs=total_CFs,
          desired_class=desired_class,
      )
  
      self.exp.final_cfs_df.Numerical = (
          self.exp.final_cfs_df.Numerical.astype(int)
      )
      self.exp.final_cfs_df = self.exp.final_cfs_df.reset_index(
          drop=True
      )
  
      expected_output = self.exp.data_interface.data_df.iloc[
          np.r_[2, 0]
      ][self.exp.data_interface.feature_names]
      expected_output = expected_output.reset_index(drop=True)
      assert all(
          self.exp.final_cfs_df.drop(columns="Outcome")
          == expected_output
      )
  
imports: import numpy
  import pytest
  from dice_ml.counterfactual_explanations import CounterfactualExplanations
  from dice_ml.diverse_counterfactuals import CounterfactualExamples
label_desc: Use image node_id 8 for calling the TestDiceKDBinaryClassificationMethods obj's underlying member method code with example usage: obj.test_duplicates(desired_class, sample_custom_query_4, total_CFs) without return types