class_docstr: An interface class to different DiCE implementations.
code: def _generate_counterfactuals(
      self,
      query_instance,
      total_CFs,
      desired_class="opposite",
      desired_range=None,
      permitted_range=None,
      features_to_vary="all",
      stopping_threshold=0.5,
      posthoc_sparsity_param=0.1,
      posthoc_sparsity_algorithm="linear",
      verbose=False,
      **kwargs,
  ):
      raise NotImplementedError(
          "This method should be implemented by the concrete classes "
          "that inherit from ExplainerBase"
      )
  
file_path: DiCE/dice_ml/dice.py
imports: from raiutils.exceptions import UserConfigValidationException
  from dice_ml.constants import BackEndTypes, SamplingStrategy
  from dice_ml.data_interfaces.private_data_interface import PrivateData
  from dice_ml.explainer_interfaces.explainer_base import ExplainerBase
label_desc: Use image node_id 3 for calling the Dice obj's underlying member method code with example usage: obj._generate_counterfactuals(query_instance, total_CFs, desired_class, desired_range, permitted_range, features_to_vary, stopping_threshold, posthoc_sparsity_param, posthoc_sparsity_algorithm, verbose) without return types