class_docstr: Hooks to be used for data related stuff.
class_docstr_tok: ["Hooks","to","be","used","for","data","related","stuff","."]
docstr: Attributes:
      prepare_data_per_node:
          If True, each LOCAL_RANK=0 will call prepare data.
          Otherwise only NODE_RANK=0, LOCAL_RANK=0 will prepare data.
      allow_zero_length_dataloader_with_multiple_devices:
          If True, dataloader with zero length within local rank is allowed.
          Default value is False.
code: def __init__(self) -> None:
      """
      Attributes:
          prepare_data_per_node:
              If True, each LOCAL_RANK=0 will call prepare data.
              Otherwise only NODE_RANK=0, LOCAL_RANK=0 will prepare data.
          allow_zero_length_dataloader_with_multiple_devices:
              If True, dataloader with zero length within local rank is allowed.
              Default value is False.
      """
      super().__init__()
      self.prepare_data_per_node: bool = True
      self.allow_zero_length_dataloader_with_multiple_devices: bool = (
          False
      )
  
imports: from typing import Any, Dict, Optional
  import torch
  from torch import Tensor
  from torch.optim.optimizer import Optimizer
  from lightning.fabric.utilities.imports import _TORCH_GREATER_EQUAL_2_0
  from lightning.pytorch.utilities import move_data_to_device
  from lightning.pytorch.utilities.exceptions import MisconfigurationException
  from lightning.pytorch.utilities.types import EVAL_DATALOADERS, STEP_OUTPUT, TRAIN_DATALOADERS
label_desc: Use image node_id 1 to create a new DataHooks object  with example: obj = DataHooks()