docstr: Args:
      flow_preds: list of flow predictions of shape (batch_size, C, H, W)
      flow_gt: ground truth flow of shape (batch_size, C, H, W)
      valid_flow_mask: mask of valid flow pixels of shape (batch_size, H, W)
code: def forward(
      self,
      flow_preds: List[Tensor],
      flow_gt: Tensor,
      valid_flow_mask: Optional[Tensor],
  ) -> Tensor:
      """
      Args:
          flow_preds: list of flow predictions of shape (batch_size, C, H, W)
          flow_gt: ground truth flow of shape (batch_size, C, H, W)
          valid_flow_mask: mask of valid flow pixels of shape (batch_size, H, W)
      """
      loss, weights = _sequence_loss_fn(
          flow_preds,
          flow_gt,
          valid_flow_mask,
          self.gamma,
          self.max_flow,
          self.excluding_large,
          self._weights,
      )
      self._weights = weights
      return loss
  
imports: from typing import List, Optional
  import torch
  from torch import nn, Tensor
  from torch.nn import functional
  from torchvision.prototype.models.depth.stereo.raft_stereo import grid_sample, make_coords_grid
label_desc: Use image node_id 2 for calling the SequenceLoss obj's underlying member method code with example usage: obj.forward(flow_preds, flow_gt, valid_flow_mask) and returns: loss