class_docstr: Skipping Memory Net
  
  args:
      input_size: int, dimension of the input feature.
          Input shape shoud be (batch, length, input_size)
      hidden_size: int, dimension of the hidden state.
      output_size: int, dimension of the output size.
      dropout: float, dropout ratio. Default is 0.
      num_blocks: number of basic SkiM blocks
      segment_size: segmentation size for splitting long features
      bidirectional: bool, whether the RNN layers are bidirectional.
      mem_type: 'hc', 'h', 'c', 'id' or None.
          It controls whether the hidden (or cell) state of SegLSTM
          will be processed by MemLSTM.
          In 'id' mode, both the hidden and cell states will
          be identically returned.
          When mem_type is None, the MemLSTM will be removed.
      norm_type: gLN, cLN. cLN is for causal implementation.
      seg_overlap: Bool, whether the segmentation will reserve 50%
          overlap for adjacent segments.Default is False.
class_docstr_tok: ["Skipping","Memory","Net","args",":","input_size",":","int",",","dimension","of","the","input","feature",".","Input","shape","shoud","be","(","batch",",","length",",","input_size",")","hidden_size",":","int",",","dimension","of","the","hidden","state",".","output_size",":","int",",","dimension","of","the","output","size",".","dropout",":","float",",","dropout","ratio",".","Default","is","0.","num_blocks",":","number","of","basic","SkiM","blocks","segment_size",":","segmentation","size","for","splitting","long","features","bidirectional",":","bool",",","whether","the","RNN","layers","are","bidirectional",".","mem_type",":","'hc","'",",","'","h","'",",","'","c","'",",","'id","'","or","None",".","It","controls","whether","the","hidden","(","or","cell",")","state","of","SegLSTM","will","be","processed","by","MemLSTM",".","In","'id","'","mode",",","both","the","hidden","and","cell","states","will","be","identically","returned",".","When","mem_type","is","None",",","the","MemLSTM","will","be","removed",".","norm_type",":","gLN",",","cLN",".","cLN","is","for","causal","implementation",".","seg_overlap",":","Bool",",","whether","the","segmentation","will","reserve","50","%","overlap","for","adjacent","segments.Default","is","False","."]
code: def _padfeature(self, input):
      B, T, D = input.shape
      rest = self.segment_size - T % self.segment_size
  
      if rest > 0:
          input = torch.nn.functional.pad(input, (0, 0, 0, rest))
      return input, rest
  
file_path: espnet/espnet2/enh/layers/skim.py
imports: import torch
  import torch.nn
  from espnet2.enh.layers.dprnn import SingleRNN, merge_feature, split_feature
  from espnet2.enh.layers.tcn import choose_norm
label_desc: Use image node_id 3 for calling the SkiM obj's underlying member method code with example usage: obj._padfeature(input) and returns: input,  rest