class_docstr: Base callback class.
  
  .. note::
  
      All callbacks should override this class.
class_docstr_tok: ["Base","callback","class",".","..","note",":",":","All","callbacks","should","override","this","class","."]
docstr: Perform some action with the state after all other callbacks have completed at the end of an epoch and the
  history has been updated. Should only be used for taking checkpoints or snapshots and will only be called by the
  run method of Trial.
  
  Args:
      state (dict): The current state dict of the :class:`.Trial`.
docstr_tok: ["Perform","some","action","with","the","state","after","all","other","callbacks","have","completed","at","the","end","of","an","epoch","and","the","history","has","been","updated",".","Should","only","be","used","for","taking","checkpoints","or","snapshots","and","will","only","be","called","by","the","run","method","of","Trial",".","Args",":","state","(","dict",")",":","The","current","state","dict","of","the",":","class",":","`",".Trial","`","."]
code: def on_checkpoint(self, state):
      """Perform some action with the state after all other callbacks have completed at the end of an epoch and the
      history has been updated. Should only be used for taking checkpoints or snapshots and will only be called by the
      run method of Trial.
  
      Args:
          state (dict): The current state dict of the :class:`.Trial`.
      """
      pass
  
imports: import functools
  import traceback
  import warnings
  import torch
  from packaging import version
  import torchbearer
  import sys
label_desc: Use image node_id 21 for calling the Callback obj's underlying member method code with example usage: obj.on_checkpoint(state) without return types