code: def is_port_in_use(port_num):
      """Check does any of child process uses specified port."""
      parent_process = psutil.Process()
      child_pids = [
          x.pid for x in parent_process.children(recursive=True)
      ]
      conns = net_connections()
      portsinuse = [
          x.laddr[1]
          for x in conns
          if x.pid in child_pids and x.status == "LISTEN"
      ]
      portsinuse.sort()
      return int(port_num) in portsinuse
  
file_path: mindsdb/tests/integration_tests/flows/ps.py
imports: import sys
  import time
  from collections import namedtuple
  import psutil
label_desc: Use image node_id 2 for calling a global function with example usage: is_port_in_use(port_num) and returns: unknown