code: def main(args):
      log.info("start")
  
      worker_num = int(os.getenv("PADDLE_TRAINERS_NUM", "0"))
      num_devices = int(os.getenv("CPU_NUM", 10))
  
      model = GraphsageModel(args)
      loss = model.forward()
      train_iter = reader.get_iter(args, model.graph_wrapper, "train")
      pyreader = fake_py_reader(train_iter, num_devices)
  
      # init fleet
      init_role()
  
      optimization(args.lr, loss, args.optimizer)
  
      # init and run server or worker
      if fleet.is_server():
          fleet.init_server(args.warm_start_from_dir)
          fleet.run_server()
  
      if fleet.is_worker():
          log.info("start init worker done")
          fleet.init_worker()
          # just the worker, load the sample
          log.info("init worker done")
  
          exe = F.Executor(F.CPUPlace())
          exe.run(fleet.startup_program)
          log.info("Startup done")
  
          compiled_prog = build_complied_prog(fleet.main_program, loss)
          train_prog(exe, compiled_prog, model, pyreader, args)
  
file_path: PGL/legacy/examples/distribute_graphsage/cluster_train.py
imports: import argparse
  import time
  import os
  import math
  import numpy
  import paddle.fluid
  import paddle.fluid.layers
  from paddle.fluid.incubate.fleet.parameter_server.distribute_transpiler import fleet
  from paddle.fluid.transpiler.distribute_transpiler import DistributeTranspilerConfig
  import paddle.fluid.incubate.fleet.base.role_maker
  from pgl.utils.logger import log
  from model import GraphsageModel
  from utils import load_config
  import reader
label_desc: Use image node_id 6 for calling a global function with example usage: main(args) without return types