docstr: Forward.
  
  Args:
      input (torch.Tensor or ComplexTensor): Encoded feature [B, T, N]
      ilens (torch.Tensor): input lengths [Batch]
      additional (Dict or None): other data included in model
          NOTE: not used in this model
  
  Returns:
      masked (List[Union(torch.Tensor, ComplexTensor)]): [(B, T, N), ...]
      ilens (torch.Tensor): (B,)
      others predicted data, e.g. masks: OrderedDict[
          'mask_spk1': torch.Tensor(Batch, Frames, Freq),
          'mask_spk2': torch.Tensor(Batch, Frames, Freq),
          ...
          'mask_spkn': torch.Tensor(Batch, Frames, Freq),
      ]
docstr_tok: ["Forward",".","Args",":","input","(","torch.Tensor","or","ComplexTensor",")",":","Encoded","feature","[","B",",","T",",","N","]","ilens","(","torch.Tensor",")",":","input","lengths","[","Batch","]","additional","(","Dict","or","None",")",":","other","data","included","in","model","NOTE",":","not","used","in","this","model","Returns",":","masked","(","List","[","Union","(","torch.Tensor",",","ComplexTensor",")","]",")",":","[","(","B",",","T",",","N",")",",","...","]","ilens","(","torch.Tensor",")",":","(","B",",",")","others","predicted","data",",","e.g",".","masks",":","OrderedDict","[","'mask_spk1","'",":","torch.Tensor","(","Batch",",","Frames",",","Freq",")",",","'mask_spk2","'",":","torch.Tensor","(","Batch",",","Frames",",","Freq",")",",","...","'mask_spkn","'",":","torch.Tensor","(","Batch",",","Frames",",","Freq",")",",","]"]
code: def forward(
      self,
      input: Union[torch.Tensor, ComplexTensor],
      ilens: torch.Tensor,
      additional: Optional[Dict] = None,
  ) -> Tuple[
      List[Union[torch.Tensor, ComplexTensor]],
      torch.Tensor,
      OrderedDict,
  ]:
      """Forward.
  
      Args:
          input (torch.Tensor or ComplexTensor): Encoded feature [B, T, N]
          ilens (torch.Tensor): input lengths [Batch]
          additional (Dict or None): other data included in model
              NOTE: not used in this model
  
      Returns:
          masked (List[Union(torch.Tensor, ComplexTensor)]): [(B, T, N), ...]
          ilens (torch.Tensor): (B,)
          others predicted data, e.g. masks: OrderedDict[
              'mask_spk1': torch.Tensor(Batch, Frames, Freq),
              'mask_spk2': torch.Tensor(Batch, Frames, Freq),
              ...
              'mask_spkn': torch.Tensor(Batch, Frames, Freq),
          ]
      """
  
      # if complex spectrum,
      if is_complex(input):
          feature = abs(input)
      else:
          feature = input
  
      B, T, N = feature.shape
  
      feature = feature.transpose(1, 2)  # B, N, T
      segmented, rest = split_feature(
          feature, segment_size=self.segment_size
      )  # B, N, L, K
  
      processed = self.dprnn(segmented)  # B, N*num_spk, L, K
  
      processed = merge_feature(processed, rest)  # B, N*num_spk, T
  
      processed = processed.transpose(1, 2)  # B, T, N*num_spk
      processed = processed.view(B, T, N, self.num_outputs)
      masks = self.nonlinear(processed).unbind(dim=3)
  
      if self.predict_noise:
          *masks, mask_noise = masks
      masked = [input * m for m in masks]
  
      others = OrderedDict(
          zip(
              ["mask_spk{}".format(i + 1) for i in range(len(masks))],
              masks,
          )
      )
      if self.predict_noise:
          others["noise1"] = input * mask_noise
  
      return masked, ilens, others
  
file_path: espnet/espnet2/enh/separator/dprnn_separator.py
imports: from collections import OrderedDict
  from typing import Dict, List, Optional, Tuple, Union
  import torch
  from packaging.version import parse
  from torch_complex.tensor import ComplexTensor
  from espnet2.enh.layers.complex_utils import is_complex
  from espnet2.enh.layers.dprnn import DPRNN, merge_feature, split_feature
  from espnet2.enh.separator.abs_separator import AbsSeparator
label_desc: Use image node_id 2 for calling the DPRNNSeparator obj's underlying member method code with example usage: obj.forward(input, ilens, additional) and returns: masked,  ilens,  others