class_docstr: Class that handles the logic of composing the visualizations.
  
  Args:
      mode (VisualizationMode): visualization mode, either "full" or "simple"
      task (TaskType): task type "segmentation", "detection" or "classification"
docstr: Generate the full set of visualization for an image.
  
  The full visualization mode shows a grid with subplots that contain the original image, the GT mask (if
  available), the predicted heat map, the predicted segmentation mask (if available), and the predicted
  segmentations (if available).
  
  Args:
      image_result (ImageResult): GT and Prediction data for a single image.
  
  Returns:
      An image showing the full set of visualizations for the input image.
docstr_tok: ["Generate","the","full","set","of","visualization","for","an","image",".","The","full","visualization","mode","shows","a","grid","with","subplots","that","contain","the","original","image",",","the","GT","mask","(","if","available",")",",","the","predicted","heat","map",",","the","predicted","segmentation","mask","(","if","available",")",",","and","the","predicted","segmentations","(","if","available",")",".","Args",":","image_result","(","ImageResult",")",":","GT","and","Prediction","data","for","a","single","image",".","Returns",":","An","image","showing","the","full","set","of","visualizations","for","the","input","image","."]
code: def _visualize_full(self, image_result: ImageResult) -> np.ndarray:
      """Generate the full set of visualization for an image.
  
      The full visualization mode shows a grid with subplots that contain the original image, the GT mask (if
      available), the predicted heat map, the predicted segmentation mask (if available), and the predicted
      segmentations (if available).
  
      Args:
          image_result (ImageResult): GT and Prediction data for a single image.
  
      Returns:
          An image showing the full set of visualizations for the input image.
      """
      visualization = ImageGrid()
      if self.task == TaskType.DETECTION:
          assert image_result.pred_boxes is not None
          visualization.add_image(image_result.image, "Image")
          if image_result.gt_boxes is not None:
              gt_image = draw_boxes(
                  np.copy(image_result.image),
                  image_result.gt_boxes,
                  color=(255, 0, 0),
              )
              visualization.add_image(
                  image=gt_image, color_map="gray", title="Ground Truth"
              )
          else:
              visualization.add_image(image_result.image, "Image")
          pred_image = draw_boxes(
              np.copy(image_result.image),
              image_result.normal_boxes,
              color=(0, 255, 0),
          )
          pred_image = draw_boxes(
              pred_image,
              image_result.anomalous_boxes,
              color=(255, 0, 0),
          )
          visualization.add_image(pred_image, "Predictions")
      if self.task == TaskType.SEGMENTATION:
          assert image_result.pred_mask is not None
          visualization.add_image(image_result.image, "Image")
          if image_result.gt_mask is not None:
              visualization.add_image(
                  image=image_result.gt_mask,
                  color_map="gray",
                  title="Ground Truth",
              )
          visualization.add_image(
              image_result.heat_map, "Predicted Heat Map"
          )
          visualization.add_image(
              image=image_result.pred_mask,
              color_map="gray",
              title="Predicted Mask",
          )
          visualization.add_image(
              image=image_result.segmentations,
              title="Segmentation Result",
          )
      elif self.task == TaskType.CLASSIFICATION:
          visualization.add_image(image_result.image, title="Image")
          if hasattr(image_result, "heat_map"):
              visualization.add_image(
                  image_result.heat_map, "Predicted Heat Map"
              )
          if image_result.pred_label:
              image_classified = add_anomalous_label(
                  image_result.image, image_result.pred_score
              )
          else:
              image_classified = add_normal_label(
                  image_result.image, 1 - image_result.pred_score
              )
          visualization.add_image(
              image=image_classified, title="Prediction"
          )
  
      return visualization.generate()
  
imports: from __future__ import annotations
  from dataclasses import dataclass, field
  from enum import Enum
  from pathlib import Path
  from typing import Iterator
  import cv2
  import matplotlib.figure
  import matplotlib.pyplot
  import numpy
  from skimage.segmentation import mark_boundaries
  from anomalib.data import TaskType
  from anomalib.data.utils import read_image
  from anomalib.post_processing.post_process import add_anomalous_label, add_normal_label, draw_boxes, superimpose_anomaly_map
label_desc: Use image node_id 4 for calling the Visualizer obj's underlying member method code with example usage: obj._visualize_full(image_result) and returns: visualization