code: def instantiate_datamodule(self):
      logger.info(
          f"Instantiating datamodule <{self.cfg.datamodule._target_}>"
      )
      # Calling this self.datamodule will mess with PL since it also assigns self.datamodule
      self._datamodule: LightningDataModule = hydra.utils.instantiate(
          self.cfg.datamodule
      )
      self._datamodule.prepare_data()
      self._datamodule.setup()
      OmegaConf.clear_resolver("datamodule")
      OmegaConf.register_new_resolver(
          "datamodule", lambda attr: getattr(self._datamodule, attr)
      )
  
imports: from typing import Any, List
  import inspect
  import torch
  import hydra
  from pytorch_lightning import LightningModule, LightningDataModule
  from torchmetrics import MetricCollection
  from einops import rearrange
  from omegaconf import OmegaConf
  from src.utils.utils import get_logger
  from src.optim.param_grouping import group_parameters_for_optimizer
  from src.utils.checkpoint import load_checkpoint
  import datasets
label_desc: Use image node_id 2 for calling the SequenceModel obj's underlying member method code with example usage: obj.instantiate_datamodule() without return types