class_docstr: Beam search for language/decoder only models
class_docstr_tok: ["Beam","search","for","language\/decoder","only","models"]
docstr: Initialize for decoding.
  Repeat src objects `beam_size` times.
docstr_tok: ["Initialize","for","decoding",".","Repeat","src","objects","`","beam_size","`","times","."]
code: def initialize(
      self, src, src_len, src_map=None, device=None, target_prefix=None
  ):
      """Initialize for decoding.
      Repeat src objects `beam_size` times.
      """
      (fn_map_state, _, src_map, target_prefix) = self.initialize_tile(
          None, src_len, src_map, target_prefix
      )
      if device is None:
          device = src.device
  
      super(BeamSearchLM, self).initialize_(
          None,
          src_map=src_map,
          device=device,
          target_prefix=target_prefix,
      )
  
      return fn_map_state, src, src_map
  
imports: import torch
  from onmt.translate import penalties
  from onmt.translate.decode_strategy import DecodeStrategy
  import warnings
label_desc: Use image node_id 1 for calling the BeamSearchLM obj's underlying member method code with example usage: obj.initialize(src, src_len, src_map, device, target_prefix) and returns: fn_map_state,  src,  src_map