code: def dropout_add(
      x: torch.Tensor,
      residual: torch.Tensor,
      prob: float,
      training: bool,
  ):
      """
      Dropout add function
  
      Args:
          x (`torch.tensor`, *required*):
              input tensor
          residual (`torch.tensor`, *required*):
              residual tensor
          prob (`float`, *required*):
              dropout probability
          training (`bool`, *required*):
              training mode
      """
      out = F.dropout(x, p=prob, training=training)
      out = residual + out
      return out
  
imports: from typing import Optional, Tuple
  import torch
  import torch.utils.checkpoint
  from torch.nn import functional
  from bigdl.llm.transformers.models.utils import init_kv_cache, extend_kv_cache, append_kv_cache
label_desc: Use image node_id 1 for calling a global function with example usage: dropout_add(x, residual, prob, training) and returns: out