class_docstr: Generate Anomaly Heatmap.
  
  Args:
      image_size (ListConfig, tuple): Size of the input image. The anomaly map is upsampled to this dimension.
      sigma (int, optional): Standard deviation for Gaussian Kernel. Defaults to 4.
docstr: Returns anomaly_map.
  
  Expects `embedding`, `mean` and `covariance` keywords to be passed explicitly.
  
  Example:
  >>> anomaly_map_generator = AnomalyMapGenerator(image_size=input_size)
  >>> output = anomaly_map_generator(embedding=embedding, mean=mean, covariance=covariance)
  
  Raises:
      ValueError: `embedding`. `mean` or `covariance` keys are not found
  
  Returns:
      torch.Tensor: anomaly map
docstr_tok: ["Returns","anomaly_map",".","Expects","`","embedding","`",",","`","mean","`","and","`","covariance","`","keywords","to","be","passed","explicitly",".","Example",":",">",">",">","anomaly_map_generator","=","AnomalyMapGenerator","(","image_size=input_size",")",">",">",">","output","=","anomaly_map_generator","(","embedding=embedding",",","mean=mean",",","covariance=covariance",")","Raises",":","ValueError",":","`","embedding","`",".","`","mean","`","or","`","covariance","`","keys","are","not","found","Returns",":","torch.Tensor",":","anomaly","map"]
code: def forward(self, **kwargs) -> Tensor:
      """Returns anomaly_map.
  
      Expects `embedding`, `mean` and `covariance` keywords to be passed explicitly.
  
      Example:
      >>> anomaly_map_generator = AnomalyMapGenerator(image_size=input_size)
      >>> output = anomaly_map_generator(embedding=embedding, mean=mean, covariance=covariance)
  
      Raises:
          ValueError: `embedding`. `mean` or `covariance` keys are not found
  
      Returns:
          torch.Tensor: anomaly map
      """
  
      if not (
          "embedding" in kwargs
          and "mean" in kwargs
          and "inv_covariance" in kwargs
      ):
          raise ValueError(
              f"Expected keys `embedding`, `mean` and `covariance`. Found {kwargs.keys()}"
          )
  
      embedding: Tensor = kwargs["embedding"]
      mean: Tensor = kwargs["mean"]
      inv_covariance: Tensor = kwargs["inv_covariance"]
  
      return self.compute_anomaly_map(embedding, mean, inv_covariance)
  
file_path: anomalib/src/anomalib/models/padim/anomaly_map.py
imports: from __future__ import annotations
  import torch
  import torch.nn.functional
  from omegaconf import ListConfig
  from torch import Tensor, nn
  from anomalib.models.components import GaussianBlur2d
label_desc: Use image node_id 6 for calling the AnomalyMapGenerator obj's underlying member method code with example usage: obj.forward() and returns: self