code: def __init__(
      self,
      client,
      interval: Union[int, float] = HEARTBEAT_INTERVAL_DEFAULT,
  ):
      self._remote_client = weakref.ref(client)
      self._heartbeat_send_interval = interval
  
      # network state check vars
      self._network_stability_check_interval = (
          RPCHeartbeatSender.NETWORK_CHECK_INTERVAL
      )
      self._network_unstable_warned = False
      self._network_absent_warned = False
      self._heartbeat_responses = Counter(success=0, fail=0)
  
      # Start thread to collect stats and logs at intervals
      self._th_collector = Thread(target=self._target_f, daemon=True)
      self._shutdown = False
      self._started = False
  
imports: import datetime
  import logging
  import time
  import weakref
  from collections import Counter
  from threading import Thread
  from typing import Union
  import aim.ext.transport.proto.remote_router_pb2
label_desc: Use image node_id 1 to create a new RPCHeartbeatSender object from inherited base classes: object with example: obj = RPCHeartbeatSender(client, interval)