class_docstr: Implementation of Region Perturbation by Samek et al., 2015.
  
  Consider a greedy iterative procedure that consists of measuring how the class
  encoded in the image (e.g. as measured by the function f) disappears when we
  progressively remove information from the image x, a process referred to as
  region perturbation, at the specified locations.
  
  Assumptions:
      - The original metric definition relies on image-patch functionality. Therefore, only apply the
      metric to 3-dimensional (image) data. To extend the applicablity to other data domains,
      adjustments to the current implementation might be necessary.
  
  References:
      1) Wojciech Samek et al.: "Evaluating the visualization of what a deep
      neural network has learned." IEEE transactions on neural networks and
      learning systems 28.11 (2016): 2660-2673.
  
  Attributes:
      -  _name: The name of the metric.
      - _data_applicability: The data types that the metric implementation currently supports.
      - _models: The model types that this metric can work with.
      - score_direction: How to interpret the scores, whether higher/ lower values are considered better.
      - evaluation_category: What property/ explanation quality that this metric measures.
class_docstr_tok: ["Implementation","of","Region","Perturbation","by","Samek","et","al.",",","2015",".","Consider","a","greedy","iterative","procedure","that","consists","of","measuring","how","the","class","encoded","in","the","image","(","e.g",".","as","measured","by","the","function","f",")","disappears","when","we","progressively","remove","information","from","the","image","x",",","a","process","referred","to","as","region","perturbation",",","at","the","specified","locations",".","Assumptions",":","-","The","original","metric","definition","relies","on","image-patch","functionality",".","Therefore",",","only","apply","the","metric","to","3-dimensional","(","image",")","data",".","To","extend","the","applicablity","to","other","data","domains",",","adjustments","to","the","current","implementation","might","be","necessary",".","References",":","1",")","Wojciech","Samek","et","al",".",":","``","Evaluating","the","visualization","of","what","a","deep","neural","network","has","learned",".","''","IEEE","transactions","on","neural","networks","and","learning","systems","28.11","(","2016",")",":","2660-2673",".","Attributes",":","-","_name",":","The","name","of","the","metric",".","-","_data_applicability",":","The","data","types","that","the","metric","implementation","currently","supports",".","-","_models",":","The","model","types","that","this","metric","can","work","with",".","-","score_direction",":","How","to","interpret","the","scores",",","whether","higher\/","lower","values","are","considered","better",".","-","evaluation_category",":","What","property\/","explanation","quality","that","this","metric","measures","."]
docstr: Calculate the area under the curve (AUC) score for several test samples.
docstr_tok: ["Calculate","the","area","under","the","curve","(","AUC",")","score","for","several","test","samples","."]
code: def get_auc_score(self):
      """Calculate the area under the curve (AUC) score for several test samples."""
      return np.mean(
          [
              utils.calculate_auc(np.array(curve))
              for curve in self.evaluation_scores
          ]
      )
  
file_path: Quantus/quantus/metrics/faithfulness/region_perturbation.py
imports: import itertools
  import sys
  from typing import Any, Callable, Dict, List, Optional
  import numpy
  from quantus.functions.perturb_func import baseline_replacement_by_indices
  from quantus.helpers import asserts, plotting, utils, warn
  from quantus.helpers.enums import DataType, EvaluationCategory, ModelType, ScoreDirection
  from quantus.helpers.model.model_interface import ModelInterface
  from quantus.helpers.perturbation_utils import make_perturb_func
  from quantus.metrics.base import Metric
label_desc: Use image node_id 4 for calling the RegionPerturbation obj's underlying member method code with example usage: obj.get_auc_score() and returns: np