code: def kill_process(process):
      """
      Stop a opened subprocess.
      """
      if type(process) == str:  # server_id, use os.kill to terminate
          pid = get_process_pid(process)
          if pid == -1:  # we use -1 to mark dead process
              return
          try:
              os.kill(pid, signal.SIGKILL)
          except Exception:
              pass
      else:
          pid = process.pid
          process.kill()
          try:
              process.wait(10)
          except Exception:
              pass
  
imports: import copy
  import json
  import os
  import random
  import re
  import signal
  import string
  from collections import defaultdict
  from subprocess import Popen
  from subprocess import STDOUT
  import google.protobuf.json_format
  import google.protobuf.text_format
  import psutil
  import requests
  from .proto.model_config_pb2 import ModelConfig
  from visualdl.utils.dir import FASTDEPLOYSERVER_PATH
label_desc: Use image node_id 21 for calling a global function with example usage: kill_process(process) without return types