code: def send_forward_recv_backward(
      output_tensor: torch.Tensor,
      tensor_shape: Shape,
      *,
      dtype: Optional[torch.dtype] = None,
      async_comm: bool = False,
      sequence_parallel_enabled: bool = False,
      sync_batch_comm: bool = True,
      batch_p2p_comm: bool = True,
      timers: _Timers = None,
  ) -> Union[torch.Tensor, FutureTensor, None]:
      """Batched send and recv with next rank in pipeline."""
      if parallel_state.is_pipeline_last_stage():
          return None
      # if timers is not None:
      #     timers("forward-send-backward-recv").start()
      _, output_tensor_grad, _ = _communicate(
          tensor_send_next=output_tensor,
          tensor_send_prev=None,
          recv_prev=False,
          recv_next=True,
          tensor_shape=tensor_shape,
          dtype_=dtype,
          async_comm=async_comm,
          sequence_parallel_enabled=sequence_parallel_enabled,
          sync_batch_comm=sync_batch_comm,
          batch_p2p_comm=batch_p2p_comm,
      )
      # if timers is not None:
      #     timers("forward-send-backward-recv").stop()
      return output_tensor_grad
  
imports: from functools import reduce
  import operator
  from typing import Union, Optional, Tuple
  import torch
  from apex.transformer import parallel_state
  from apex.transformer.log_util import get_transformer_logger
  from apex.transformer.utils import split_tensor_into_1d_equal_chunks
  from apex.transformer.utils import gather_split_1d_tensor
  from apex.transformer.pipeline_parallel.utils import Shape
  from apex.transformer.pipeline_parallel._timers import _Timers
label_desc: Use image node_id 7 for calling a global function with example usage: send_forward_recv_backward(output_tensor, tensor_shape) and returns: output_tensor_grad, None