code: def train_mp(
      args,
      model,
      train_sampler,
      valid_samplers=None,
      test_samplers=None,
      rank=0,
      rel_parts=None,
      cross_rels=None,
      barrier=None,
  ):
      if args.num_proc > 1:
          th.set_num_threads(args.num_thread)
      train(
          args,
          model,
          train_sampler,
          valid_samplers,
          test_samplers,
          rank,
          rel_parts,
          cross_rels,
          barrier,
      )
  
imports: import torch.multiprocessing
  from torch.utils.data import DataLoader
  import torch.optim
  import torch
  from distutils.version import LooseVersion
  from .models.pytorch.tensor_models import thread_wrapped_func
  from .models import KEModel
  from .utils import save_model, get_compatible_batch_size
  import os
  import logging
  import time
  from functools import wraps
  import dgl
  from dgl.contrib import KVClient
  import dgl.backend
  from .dataloader import EvalDataset
  from .dataloader import get_dataset
  import pdb
  from collections import defaultdict
  from ogb.lsc import WikiKG90MDataset, WikiKG90MEvaluator
  from tqdm.auto import tqdm
  import pickle
  from math import ceil
label_desc: Use image node_id 5 for calling a global function with example usage: train_mp(args, model, train_sampler, valid_samplers, test_samplers, rank, rel_parts, cross_rels, barrier) without return types