class_docstr: AnomalyModule to train, validate, predict and test images.
  
  Acts as a base class for all the Anomaly Modules in the library.
class_docstr_tok: ["AnomalyModule","to","train",",","validate",",","predict","and","test","images",".","Acts","as","a","base","class","for","all","the","Anomaly","Modules","in","the","library","."]
docstr: Forward-pass input tensor to the module.
  
  Args:
      batch (dict[str, str | Tensor]): Input batch.
  
  Returns:
      Tensor: Output tensor from the model.
docstr_tok: ["Forward-pass","input","tensor","to","the","module",".","Args",":","batch","(","dict","[","str",",","str","|","Tensor","]",")",":","Input","batch",".","Returns",":","Tensor",":","Output","tensor","from","the","model","."]
code: def forward(
      self, batch: dict[str, str | Tensor], *args, **kwargs
  ) -> Any:
      """Forward-pass input tensor to the module.
  
      Args:
          batch (dict[str, str | Tensor]): Input batch.
  
      Returns:
          Tensor: Output tensor from the model.
      """
      del args, kwargs  # These variables are not used.
  
      return self.model(batch)
  
imports: from __future__ import annotations
  import importlib
  import logging
  from abc import ABC
  from typing import Any, OrderedDict
  from warnings import warn
  import pytorch_lightning
  import torch
  from pytorch_lightning.callbacks import Callback
  from pytorch_lightning.utilities.types import EPOCH_OUTPUT, STEP_OUTPUT
  from torch import Tensor, nn
  from torchmetrics import Metric
  from anomalib.data.utils import boxes_to_anomaly_maps, boxes_to_masks, masks_to_boxes
  from anomalib.post_processing import ThresholdMethod
  from anomalib.utils.metrics import AnomalibMetricCollection, AnomalyScoreDistribution, AnomalyScoreThreshold, MinMax
label_desc: Use image node_id 2 for calling the AnomalyModule obj's underlying member method code with example usage: obj.forward(batch) and returns: self