code: def register_task(self, client, task_f, *args):
      if not self._client:
          self._client = weakref.ref(client)
  
      if self._shutdown:
          logger.debug(
              "Cannot register task: rpc task queue is stopped."
          )
          return
  
      arg_size = self._calculate_size(args)
      with self._queue.not_full:
          while (
              self.current_memory_usage + arg_size
              >= self.max_memory_usage
          ):
              self._queue.not_full.wait()
  
      with self._queue.mutex:
          self.current_memory_usage += arg_size
  
      self._queue.put((task_f, args))
  
file_path: aim/aim/ext/transport/rpc_queue.py
imports: import time
  import queue
  import logging
  import threading
  import weakref
label_desc: Use image node_id 2 for calling the RpcQueueWithRetry obj's underlying member method code with example usage: obj.register_task(client, task_f) without return types