code: def combine_states(cls, states):
      batch_indices = [
          batch_index
          for state in states
          for batch_index in state.batch_indices
      ]
      action_histories = [
          action_history
          for state in states
          for action_history in state.action_history
      ]
      scores = [score for state in states for score in state.score]
      start_values = [
          start_value
          for state in states
          for start_value in state.start_values
      ]
      return SimpleDecoderState(
          batch_indices, action_histories, scores, start_values
      )
  
file_path: magnitude/pymagnitude/third_party/allennlp/tests/nn/decoding/simple_transition_system.py
imports: from __future__ import absolute_import
  from collections import defaultdict
  import torch
  from allennlp.nn.decoding import DecoderState, DecoderStep
label_desc: Use image node_id 3 for calling the SimpleDecoderState obj's underlying member method code with example usage: obj.combine_states(cls, states) and returns: SimpleDecoderState