class_docstr: Hexagon Launcher for Android.
class_docstr_tok: ["Hexagon","Launcher","for","Android","."]
docstr: Setup the ADB connection and execute the server script.
docstr_tok: ["Setup","the","ADB","connection","and","execute","the","server","script","."]
code: def _run_server_script(self):
      """Setup the ADB connection and execute the server script."""
  
      # Collect any existing adb port forwarding to avoid duplication
      # with another running process
      existing_forwards = self._process_forwarded_ports()
      # Enable port reverse for RPC tracker
      rpc_tracker_port = self._rpc_info["rpc_tracker_port"]
      rpc_server_port = self._rpc_info["rpc_server_port"]
  
      self._reverse_ports(rpc_tracker_port)
      self._forward_ports(rpc_server_port, existing_forwards)
  
      # Run server and connect to tracker
      subprocess.Popen(
          self._adb_device_sub_cmd
          + [
              "shell",
              f"cd {self._workspace} && ./{ANDROID_BASH_FILE_NAME}",
          ],
          stdout=subprocess.PIPE,
          stdin=subprocess.PIPE,
          stderr=subprocess.PIPE,
      )
  
imports: import abc
  import datetime
  import logging
  import multiprocessing
  import os
  import pathlib
  import signal
  import socket
  import stat
  import random
  import string
  import subprocess
  import sys
  import tempfile
  from typing import Union
  from tvm.contrib.hexagon.hexagon_profiler import HexagonProfiler
  from ..._ffi import libinfo
  from .session import Session
  from .tools import HEXAGON_SIMULATOR_NAME
label_desc: Use image node_id 8 for calling the HexagonLauncherAndroid obj's underlying member method code with example usage: obj._run_server_script() without return types