class_docstr: Calculate performance metrics of a given model on a given dataset.
  
  Parameters
  ----------
  scorers: Union[Dict[str, Union[Callable, str]], List[Any]] , default: None
      Scorers to override the default scorers (metrics), find more about the supported formats at
      https://docs.deepchecks.com/stable/user-guide/general/metrics_guide.html
  {additional_check_init_params:2*indent}
docstr: Add condition - the result is greater than the threshold.
  
  Parameters
  ----------
  threshold: float
      The threshold that the metrics result should be grater than.
  
  metrics: List[str]
      The names of the metrics from the check to apply the condition to. If None, runs on all of the metrics that
      were calculated in the check.
  
  class_mode: str, default: 'all'
      The decision rule over the classes, one of 'any', 'all', class name. If 'any', passes if at least one class
      result is above the threshold, if 'all' passes if all of the class results are above the threshold,
      class name, passes if the result for this specified class is above the thershold.
docstr_tok: ["Add","condition","-","the","result","is","greater","than","the","threshold",".","Parameters","--","--","--","--","--","threshold",":","float","The","threshold","that","the","metrics","result","should","be","grater","than",".","metrics",":","List","[","str","]","The","names","of","the","metrics","from","the","check","to","apply","the","condition","to",".","If","None",",","runs","on","all","of","the","metrics","that","were","calculated","in","the","check",".","class_mode",":","str",",","default",":","'all'","The","decision","rule","over","the","classes",",","one","of","'any","'",",","'all","'",",","class","name",".","If","'any","'",",","passes","if","at","least","one","class","result","is","above","the","threshold",",","if","'all","'","passes","if","all","of","the","class","results","are","above","the","threshold",",","class","name",",","passes","if","the","result","for","this","specified","class","is","above","the","thershold","."]
code: def add_condition_greater_than(
      self,
      threshold: float,
      metrics: List[str] = None,
      class_mode: str = "all",
  ):
      """Add condition - the result is greater than the threshold.
  
      Parameters
      ----------
      threshold: float
          The threshold that the metrics result should be grater than.
  
      metrics: List[str]
          The names of the metrics from the check to apply the condition to. If None, runs on all of the metrics that
          were calculated in the check.
  
      class_mode: str, default: 'all'
          The decision rule over the classes, one of 'any', 'all', class name. If 'any', passes if at least one class
          result is above the threshold, if 'all' passes if all of the class results are above the threshold,
          class name, passes if the result for this specified class is above the thershold.
      """
  
      def condition(check_result, metrics_to_check=metrics):
          metrics_to_check = (
              check_result["Metric"].unique()
              if metrics_to_check is None
              else metrics_to_check
          )
          metrics_pass = []
  
          for metric in metrics_to_check:
              if metric not in check_result.Metric.unique():
                  raise DeepchecksValueError(
                      f"The requested metric was not calculated, the metrics calculated in "
                      f"this check are: {check_result.Metric.unique()}."
                  )
              metric_result = check_result[
                  check_result["Metric"] == metric
              ]
              if class_mode == "all":
                  metrics_pass.append(
                      min(metric_result["Value"]) > threshold
                  )
              elif class_mode == "any":
                  metrics_pass.append(
                      max(metric_result["Value"]) > threshold
                  )
              elif str(class_mode) in [
                  str(x) for x in metric_result["Class Name"].unique()
              ]:
                  metrics_pass.append(
                      metric_result["Value"][class_mode] > threshold
                  )
              else:
                  raise DeepchecksValueError(
                      f"class_mode expected be one of the classes in the check results or any "
                      f"or all, received {class_mode}."
                  )
  
          if all(metrics_pass):
              return ConditionResult(
                  ConditionCategory.PASS,
                  "Passed for all of the metrics.",
              )
          else:
              failed_metrics = [
                  a
                  for a, b in zip(metrics_to_check, metrics_pass)
                  if not b
              ]
              return ConditionResult(
                  ConditionCategory.FAIL,
                  f"Failed for metrics: {failed_metrics}",
              )
  
      return self.add_condition(
          f"Score is greater than {threshold} for classes: {class_mode}",
          condition,
      )
  
imports: from numbers import Number
  from typing import TYPE_CHECKING, Any, Callable, Dict, List, Optional, Union
  from deepchecks.core import CheckResult, ConditionResult, DatasetKind
  from deepchecks.core.condition import ConditionCategory
  from deepchecks.core.errors import DeepchecksValueError
  from deepchecks.core.reduce_classes import ReduceMetricClassMixin
  from deepchecks.utils.docref import doclink
  from deepchecks.vision._shared_docs import docstrings
  from deepchecks.vision.base_checks import SingleDatasetCheck
  from deepchecks.vision.context import Context
  from deepchecks.vision.metrics_utils.scorers import get_scorers_dict, metric_results_to_df
  from deepchecks.vision.vision_data.batch_wrapper import BatchWrapper
label_desc: Use image node_id 7 for calling the SingleDatasetPerformance obj's underlying member method code with example usage: obj.add_condition_greater_than(threshold, metrics, class_mode) and returns: self, ConditionResult, ConditionResult