class_docstr: State representation used for tracking in memory state across workers.
  
  Args:
      bcast_object: Function used to broadcast a variable from rank 0 to the other workers.
      get_rank: Function that returns the current rank of this worker.
class_docstr_tok: ["State","representation","used","for","tracking","in","memory","state","across","workers",".","Args",":","bcast_object",":","Function","used","to","broadcast","a","variable","from","rank","0","to","the","other","workers",".","get_rank",":","Function","that","returns","the","current","rank","of","this","worker","."]
docstr: Register callbacks that will be invoked following a reset event (worker added or removed).
  
  For example, a common use of a reset callback would be to update the learning rate scale with the
  new number of workers.
  
  Args:
      callbacks: list of functions to execute.
docstr_tok: ["Register","callbacks","that","will","be","invoked","following","a","reset","event","(","worker","added","or","removed",")",".","For","example",",","a","common","use","of","a","reset","callback","would","be","to","update","the","learning","rate","scale","with","the","new","number","of","workers",".","Args",":","callbacks",":","list","of","functions","to","execute","."]
code: def register_reset_callbacks(self, callbacks):
      """Register callbacks that will be invoked following a reset event (worker added or removed).
  
      For example, a common use of a reset callback would be to update the learning rate scale with the
      new number of workers.
  
      Args:
          callbacks: list of functions to execute.
      """
      self._reset_callbacks.extend(callbacks)
  
imports: import functools
  import queue
  from horovod.common.exceptions import HorovodInternalError, HostsUpdatedInterrupt
  from horovod.runner.elastic.worker import HostUpdateResult, WorkerNotificationManager
label_desc: Use image node_id 2 for calling the State obj's underlying member method code with example usage: obj.register_reset_callbacks(callbacks) without return types