code: def main():
      global debug
  
      # Parse command line arguments
      parser = argparse.ArgumentParser(
          prog="qspectrumanalyzer",
          description="Spectrum analyzer for multiple SDR platforms",
      )
      parser.add_argument(
          "--debug",
          action="store_true",
          help="detailed debugging messages",
      )
      parser.add_argument(
          "--version",
          action="version",
          version="%(prog)s {}".format(__version__),
      )
      args, unparsed_args = parser.parse_known_args()
      debug = args.debug
  
      try:
          # Hide console window on Windows
          if sys.platform == "win32" and not debug:
              from qspectrumanalyzer import windows
  
              windows.set_attached_console_visible(False)
  
          # Start PyQt application
          app = QtWidgets.QApplication(sys.argv[:1] + unparsed_args)
          app.setOrganizationName("QSpectrumAnalyzer")
          app.setOrganizationDomain("qspectrumanalyzer.eutopia.cz")
          app.setApplicationName("QSpectrumAnalyzer")
          window = QSpectrumAnalyzerMainWindow()
          sys.exit(app.exec_())
      finally:
          # Unhide console window on Windows (we don't want to leave zombies behind)
          if sys.platform == "win32" and not debug:
              windows.set_attached_console_visible(True)
  
imports: import sys, os, signal, time, argparse
  from Qt import QtCore, QtGui, QtWidgets
  from qspectrumanalyzer import backends
  from qspectrumanalyzer.version import __version__
  from qspectrumanalyzer.data import DataStorage
  from qspectrumanalyzer.plot import SpectrumPlotWidget, WaterfallPlotWidget
  from qspectrumanalyzer.utils import str_to_color, human_time
  from qspectrumanalyzer.settings import QSpectrumAnalyzerSettings
  from qspectrumanalyzer.smoothing import QSpectrumAnalyzerSmoothing
  from qspectrumanalyzer.persistence import QSpectrumAnalyzerPersistence
  from qspectrumanalyzer.colors import QSpectrumAnalyzerColors
  from qspectrumanalyzer.baseline import QSpectrumAnalyzerBaseline
  from qspectrumanalyzer.ui_qspectrumanalyzer import Ui_QSpectrumAnalyzerMainWindow
label_desc: Use image node_id 1 for calling a global function with example usage: main() without return types