code: def advance(self, log_probs, attn):
      super(GreedySearchLM, self).advance(log_probs, attn)
  
      # in LM task src_len is associated with currently generated src
      # and therefore needs to follow the generation
      self.src_len += 1
  
imports: import torch
  from torch.nn.functional import softmax
  from onmt.translate.decode_strategy import DecodeStrategy
label_desc: Use image node_id 3 for calling the GreedySearchLM obj's underlying member method code with example usage: obj.advance(log_probs, attn) without return types