code: def _generate_subsequent_mask(
      target_length: int, source_length: int
  ) -> torch.Tensor:
      mask = (
          torch.triu(torch.ones(source_length, target_length)) == 1
      ).transpose(0, 1)
      mask = (
          mask.float()
          .masked_fill(mask == 0, float("-inf"))
          .masked_fill(mask == 1, float(0.0))
      )
      return mask
  
imports: from typing import List, Optional, Tuple
  import numpy
  import torch
  import torch.nn
  from pts.modules import FeatureEmbedder
label_desc: Use image node_id 2 for calling the TemporalFusionDecoder obj's underlying member method code with example usage: obj._generate_subsequent_mask(target_length, source_length) and returns: mask