code: def run_train(args):
      seed_everything(1)
      checkpoint_dir = args.exp_dir / "checkpoints"
      checkpoint = ModelCheckpoint(
          checkpoint_dir,
          monitor="Losses/val_loss",
          mode="min",
          save_top_k=5,
          save_weights_only=False,
          verbose=True,
      )
      train_checkpoint = ModelCheckpoint(
          checkpoint_dir,
          monitor="Losses/train_loss",
          mode="min",
          save_top_k=5,
          save_weights_only=False,
          verbose=True,
      )
      lr_monitor = LearningRateMonitor(logging_interval="step")
      callbacks = [
          checkpoint,
          train_checkpoint,
          lr_monitor,
      ]
      if os.path.exists(args.resume) and args.resume != "":
          trainer = Trainer(
              default_root_dir=args.exp_dir,
              max_epochs=args.epochs,
              num_nodes=args.nodes,
              gpus=args.gpus,
              accelerator="gpu",
              strategy=DDPStrategy(find_unused_parameters=False),
              callbacks=callbacks,
              reload_dataloaders_every_n_epochs=1,
              resume_from_checkpoint=args.resume,
          )
      else:
          trainer = Trainer(
              default_root_dir=args.exp_dir,
              max_epochs=args.epochs,
              num_nodes=args.nodes,
              gpus=args.gpus,
              accelerator="gpu",
              strategy=DDPStrategy(find_unused_parameters=False),
              callbacks=callbacks,
              reload_dataloaders_every_n_epochs=1,
          )
  
      model = ConformerRNNTModule(str(args.sp_model_path), args.biasing)
      data_module = get_data_module(
          str(args.librispeech_path),
          str(args.global_stats_path),
          str(args.sp_model_path),
          subset=args.subset,
          biasinglist=args.biasing_list,
          droprate=args.droprate,
          maxsize=args.maxsize,
      )
      trainer.fit(model, data_module, ckpt_path=args.checkpoint_path)
  
file_path: audio/examples/asr/librispeech_conformer_rnnt_biasing/train.py
imports: import os
  import pathlib
  from argparse import ArgumentParser
  from lightning import ConformerRNNTModule
  from pytorch_lightning import seed_everything, Trainer
  from pytorch_lightning.callbacks import LearningRateMonitor, ModelCheckpoint
  from pytorch_lightning.strategies import DDPStrategy
  from transforms import get_data_module
label_desc: Use image node_id 1 for calling a global function with example usage: run_train(args) without return types