code: def read_quartus_report(hls_dir, open_browser=False):
      """
      Parse and print the Quartus report to print the report. Optionally open a browser.
  
      Args:
          hls_dir (string):  The directory where the project is found
          open_browser, optional:  whether to open a browser
  
      Returns:
          None
      """
      report = parse_quartus_report(hls_dir)
  
      print("HLS Resource Summary\n")
      print(
          tabulate(
              list(report.items())[0:10],
              tablefmt="orgtbl",
              headers=["Resource", "Utilization"],
          )
      )
      print("\n\nHLS Validation Summary\n")
      print(
          tabulate(
              list(report.items())[11:13],
              tablefmt="orgtbl",
              headers=["", "[Min, Max, Avg]"],
          )
      )
      if "Clock" in report.keys():
          print("\n\nQuartus Synthesis Summary\n")
          print(
              tabulate(
                  list(report.items())[13:],
                  tablefmt="orgtbl",
                  headers=["Resource", "Utilization"],
              )
          )
      else:
          print(
              "Quartus compile data not found! To generate data run FPGA synthesis"
          )
  
      if open_browser:
          url = (
              "file:"
              + os.getcwd()
              + "/"
              + _find_project_dir(hls_dir)
              + "/report.html"
          )
          webbrowser.open(url)
  
file_path: hls4ml/hls4ml/report/quartus_report.py
imports: import os
  import webbrowser
  from ast import literal_eval
  from calmjs.parse import asttypes, es5
  from tabulate import tabulate
label_desc: Use image node_id 2 for calling a global function with example usage: read_quartus_report(hls_dir, open_browser) without return types