code: def initialize_sampler(model, sampler_type):
      if sampler_type == "DDIM":
          sampler = DDIMSampler(model)
      elif sampler_type == "PLMS":
          sampler = PLMSSampler(model)
      elif sampler_type == "DPM":
          sampler = DPMSolverSampler(model)
      elif sampler_type == "PARA_DDIM":
          sampler = ParaDDIMSampler(model)
      else:
          raise ValueError(f"Sampler {sampler_type} is not supported.")
      return sampler
  
file_path: NeMo/nemo/collections/multimodal/parts/stable_diffusion/pipeline.py
imports: import os
  import pickle
  import time
  import torch
  from PIL import Image
  from nemo.collections.multimodal.models.text_to_image.stable_diffusion.samplers.ddim import DDIMSampler
  from nemo.collections.multimodal.models.text_to_image.stable_diffusion.samplers.para_ddim import ParaDDIMSampler
  from nemo.collections.multimodal.models.text_to_image.stable_diffusion.samplers.plms import PLMSSampler
  from nemo.collections.multimodal.models.text_to_image.stable_diffusion.samplers.sampler_dpm import DPMSolverSampler
  from nemo.collections.multimodal.parts.stable_diffusion.utils import DataParallelWrapper
label_desc: Use image node_id 2 for calling a global function with example usage: initialize_sampler(model, sampler_type) and returns: sampler