class_docstr: Tiler Configuration Callback.
docstr: Setup Tiler object within Anomalib Model.
  
  Args:
      trainer (pl.Trainer): PyTorch Lightning Trainer
      pl_module (pl.LightningModule): Anomalib Model that inherits pl LightningModule.
      stage (str | None, optional): fit, validate, test or predict. Defaults to None.
  
  Raises:
      ValueError: When Anomalib Model doesn't contain ``Tiler`` object, it means the model
          doesn not support tiling operation.
code: def setup(
      self,
      trainer: pl.Trainer,
      pl_module: pl.LightningModule,
      stage: str | None = None,
  ) -> None:
      """Setup Tiler object within Anomalib Model.
  
      Args:
          trainer (pl.Trainer): PyTorch Lightning Trainer
          pl_module (pl.LightningModule): Anomalib Model that inherits pl LightningModule.
          stage (str | None, optional): fit, validate, test or predict. Defaults to None.
  
      Raises:
          ValueError: When Anomalib Model doesn't contain ``Tiler`` object, it means the model
              doesn not support tiling operation.
      """
      del trainer, stage  # These variables are not used.
  
      if self.enable:
          if isinstance(pl_module, AnomalyModule) and hasattr(
              pl_module.model, "tiler"
          ):
              pl_module.model.tiler = Tiler(
                  tile_size=self.tile_size,
                  stride=self.stride,
                  remove_border_count=self.remove_border_count,
                  mode=self.mode,
              )
          else:
              raise ValueError("Model does not support tiling.")
  
file_path: anomalib/src/anomalib/utils/callbacks/tiler_configuration.py
imports: from __future__ import annotations
  from typing import Sequence
  import pytorch_lightning
  from pytorch_lightning.callbacks import Callback
  from anomalib.models.components import AnomalyModule
  from anomalib.pre_processing.tiler import ImageUpscaleMode, Tiler
label_desc: Use image node_id 2 for calling the TilerConfigurationCallback obj's underlying member method code with example usage: obj.setup(trainer, pl_module, stage) without return types