code: def ssh_cmd(cmd_str, ip, ssh_key=None):
      """construct an ssh command"""
      if ssh_key is None:
          ssh_cmd_str = "ssh %s '%s'" % (ip, cmd_str)
      else:
          ssh_cmd_str = "ssh -i %s %s '%s'" % (ssh_key, ip, cmd_str)
  
      return ssh_cmd_str
  
file_path: ogb/examples/lsc/wikikg90m/dgl-ke-ogb-lsc/python/dglke/dist_train.py
imports: import os
  import stat
  import sys
  import subprocess
  import argparse
  import socket
  from .utils import CommonArgParser
label_desc: Use image node_id 6 for calling a global function with example usage: ssh_cmd(cmd_str, ip, ssh_key) and returns: ssh_cmd_str