code: def init_grad(obj, allow_lazy_initializer=False):
    
    if obj is None:
      # TODO: fixes.py appears to pass None value and expect 0.0 back. Bug?
      return 0.0
  
    initializer, supports_lazy_initializer = grad_initializers[type(obj)]
    if supports_lazy_initializer:
      if isinstance(obj, ZeroGradient):
        if allow_lazy_initializer:
          return ZeroGradient(obj.like)
        else:
          # TODO: Not sure this should normally be hit. In forward-over-reverse?
          return obj.instantiate()
      else:
        if allow_lazy_initializer:
          return ZeroGradient(obj)
    else:
      assert not isinstance(obj, ZeroGradient)
    return initializer(obj)
docs: Initialize the gradient for an object.
  
    Args:
      obj: The object to initialize the gradient for, can be either a number,
        array, tuple, list, or dictionary.
      allow_lazy_initializer: Whether to allow using the ZeroGradient wrapper,
        for efficiency.
  
    Returns:
      An object of the same type, shape, etc. but with all numeric values set to
      zero. If the type is unknown, a zero is returned.