class_docstr: the Mem-LSTM of SkiM
  
  args:
      hidden_size: int, dimension of the hidden state.
      dropout: float, dropout ratio. Default is 0.
      bidirectional: bool, whether the LSTM layers are bidirectional.
          Default is False.
      mem_type: 'hc', 'h', 'c' or 'id'.
          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.
      norm_type: gLN, cLN. cLN is for causal implementation.
class_docstr_tok: ["the","Mem-LSTM","of","SkiM","args",":","hidden_size",":","int",",","dimension","of","the","hidden","state",".","dropout",":","float",",","dropout","ratio",".","Default","is","0.","bidirectional",":","bool",",","whether","the","LSTM","layers","are","bidirectional",".","Default","is","False",".","mem_type",":","'hc","'",",","'","h","'",",","'","c","'","or","'id","'",".","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",".","norm_type",":","gLN",",","cLN",".","cLN","is","for","causal","implementation","."]
code: def __init__(
      self,
      hidden_size,
      dropout=0.0,
      bidirectional=False,
      mem_type="hc",
      norm_type="cLN",
  ):
      super().__init__()
      self.hidden_size = hidden_size
      self.bidirectional = bidirectional
      self.input_size = (int(bidirectional) + 1) * hidden_size
      self.mem_type = mem_type
  
      assert mem_type in [
          "hc",
          "h",
          "c",
          "id",
      ], f"only support 'hc', 'h', 'c' and 'id', current type: {mem_type}"
  
      if mem_type in ["hc", "h"]:
          self.h_net = SingleRNN(
              "LSTM",
              input_size=self.input_size,
              hidden_size=self.hidden_size,
              dropout=dropout,
              bidirectional=bidirectional,
          )
          self.h_norm = choose_norm(
              norm_type=norm_type,
              channel_size=self.input_size,
              shape="BTD",
          )
      if mem_type in ["hc", "c"]:
          self.c_net = SingleRNN(
              "LSTM",
              input_size=self.input_size,
              hidden_size=self.hidden_size,
              dropout=dropout,
              bidirectional=bidirectional,
          )
          self.c_norm = choose_norm(
              norm_type=norm_type,
              channel_size=self.input_size,
              shape="BTD",
          )
  
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 1 to create a new MemLSTM object from inherited base classes: nn with example: obj = MemLSTM(hidden_size, dropout, bidirectional, mem_type, norm_type)