code: def status():
      if _IS_WINDOWS:
          cmd = r"""wmic process where "commandline like '%remote\\start.py --name worker --address%'" get commandline /format:list | findstr /V wmic | findstr CommandLine="""
      else:
          cmd = r"ps -ef | grep remote/start.py\ --name\ worker\ --address"
  
      content = os.popen(cmd).read().strip()
      cpu_pattern = re.compile("--address (.*?) --cpu")
      cpu_clusters = set(cpu_pattern.findall(content))
      gpu_pattern = re.compile("--address (.*?) --cpu.*? --gpu [0-9,]+")
      gpu_clusters = set(gpu_pattern.findall(content))
      clusters = cpu_clusters | gpu_clusters
      if len(clusters) == 0:
          click.echo("No active cluster is found.")
      else:
          ctx = zmq.Context()
          status = []
          for cluster in clusters:
              if _IS_WINDOWS:
                  cmd = r"""wmic process where "commandline like '%address {}%'" get commandline /format:list | findstr /V wmic | findstr CommandLine=""".format(
                      cluster
                  )
              else:
                  cmd = r"ps -ef | grep address\ {}".format(cluster)
              content = os.popen(cmd).read()
              pattern = re.compile("--monitor_port (.*?)\n", re.S)
              monitors = pattern.findall(content)
  
              if len(monitors):
                  monitor_port = monitors[0].split(" ")[0]
                  master_address = monitors[0].split(" ")[2]
                  monitor_address = "{}:{}".format(
                      get_ip_address(), monitor_port
                  )
                  socket = ctx.socket(zmq.REQ)
                  socket.setsockopt(zmq.RCVTIMEO, 10000)
                  socket.connect("tcp://{}".format(master_address))
                  try:
                      socket.send_multipart([STATUS_TAG])
                      monitor_info = to_str(socket.recv_multipart()[1])
                  except zmq.error.Again as e:
                      click.echo(
                          "Can not connect to cluster {}, please try later.".format(
                              master_address
                          )
                      )
                      socket.close(0)
                      continue
                  msg = """
              # Cluster {} {}
  
              # If you want to check cluster status, please view: http://{}
              """.format(
                      master_address, monitor_info, monitor_address
                  )
                  status.append(msg)
                  socket.close(0)
              else:
                  msg = """
              # Cluster {} fails to start the cluster monitor.
                  """.format(
                      cluster
                  )
                  status.append(msg)
  
          for monitor_status in status:
              click.echo(monitor_status)
  
imports: import click
  import locale
  import multiprocessing
  import os
  import random
  import re
  import requests
  import subprocess
  import sys
  import time
  import threading
  import tempfile
  import warnings
  import zmq
  from multiprocessing import Process
  from parl.utils import _IS_WINDOWS, get_free_tcp_port, get_ip_address, get_port_from_range, is_port_available, kill_process, to_str
  from parl.remote.remote_constants import STATUS_TAG
  from parl.remote.utils import XPARL_PYTHON
label_desc: Use image node_id 8 for calling a global function with example usage: status() without return types