code: def __init__(self, dashboard_head):
      super().__init__(dashboard_head)
      self.usage_stats_enabled = ray_usage_lib.usage_stats_enabled()
      self.usage_stats_prompt_enabled = (
          ray_usage_lib.usage_stats_prompt_enabled()
      )
      self.cluster_config_to_report = None
      self.session_dir = dashboard_head.session_dir
      self.client = ray_usage_lib.UsageReportClient()
      # The total number of report succeeded.
      self.total_success = 0
      # The total number of report failed.
      self.total_failed = 0
      # The seq number of report. It increments whenever a new report is sent.
      self.seq_no = 0
  
      self._dashboard_url_base = f"http://{dashboard_head.http_host}:{dashboard_head.http_port}"
      # We want to record stats for anyone who has run ray with grafana or
      # prometheus at any point in time during a ray session.
      self._grafana_ran_before = False
      self._prometheus_ran_before = False
  
file_path: ray/dashboard/modules/usage_stats/usage_stats_head.py
imports: import asyncio
  import logging
  import os
  import random
  import requests
  from concurrent.futures import ThreadPoolExecutor
  import ray
  import ray._private.usage.usage_lib
  from ray._private.utils import get_or_create_event_loop
  import ray.dashboard.utils
  from ray.dashboard.utils import async_loop_forever
label_desc: Use image node_id 1 to create a new UsageStatsHead object from inherited base classes: dashboard_utils with example: obj = UsageStatsHead(dashboard_head)