class_docstr: StdTreeDecoder: This is a tree decoder implementation, which is used for tree object decoding.
  
  Attributes
  ----------
  attn_type : str,
      Describe which attention mechanism is used, can be ``uniform``,
      ``separate_on_encoder_type``, ``separate_on_node_type``.
  
  embeddings : torch.nn.Module,
      Embedding layer, input is tensor of word index, output is word embedding tensor.
  
  enc_hidden_size : int,
      Size of encoder hidden state.
  
  dec_emb_size : int,
      Size of decoder word embedding layer output size.
  
  dec_hidden_size : int,
      Size of decoder hidden state. (namely the ``lstm`` or ``gru``
      hidden size when rnn unit has been specified)
  
  output_size : int,
      Size of output vocabulary size.
  
  teacher_force_ratio : float,
      The ratio of possibility to use teacher force training.
  
  use_sibling : boolean,
      Whether feed sibling state in each decoding step.
  
  use_copy : boolean,
      Whether use copy mechanism in decoding.
  
  fuse_strategy: str, option=[None, "average", "concatenate"], default=None
      The strategy to fuse attention results generated by separate attention.
      "None": If we do ``uniform`` attention, we will set it to None.
      "``average``": We will take an average on all results.
      "``concatenate``": We will concatenate all results to one.
  
  num_layers : int, optional,
      Layer number of decoder rnn unit.
  
  dropout_for_decoder: float,
      Dropout ratio for decoder(include both the dropout for word embedding
      and the dropout for attention layer)
  
  tgt_vocab : object,
      The vocab object used in decoder, including all the word<->id pairs
      appeared in the output sentences.
  
  graph_pooling_strategy : str,
      The graph pooling strategy used to generate the graph embedding with node embeddings
  
  rnn_type: str, optional,
      The rnn unit is used, option=["lstm", "gru"], default="lstm".
  
  max_dec_seq_length : int, optional,
      In decoding, the decoding steps upper limit.
  
  max_dec_tree_depth : int, optional,
      In decoding, the tree depth lower limit.
docstr: The function used to mask some oov word in word embedding layer.
docstr_tok: ["The","function","used","to","mask","some","oov","word","in","word","embedding","layer","."]
code: def _filter_oov(self, tokens, vocab):
      r"""The function used to mask some oov word in word embedding layer."""
      ret = tokens.clone()
      ret[tokens >= vocab.vocab_size] = vocab.get_symbol_idx(
          vocab.unk_token
      )
      return ret
  
imports: import random
  import numpy
  import torch
  import torch.nn
  import torch.nn.functional
  from graph4nlp.pytorch.modules.utils.tree_utils import Tree, to_cuda
  from .attention import Attention
  from .base import RNNTreeDecoderBase
label_desc: Use image node_id 3 for calling the StdTreeDecoder obj's underlying member method code with example usage: obj._filter_oov(tokens, vocab) and returns: ret