Usage
gather_tree(step_ids, parent_ids, max_sequence_lengths, end_token)
Arguments
parent_ids
The parent ids of shape `[max_time, batch_size, beam_width]`.
max_sequence_lengths
get max_sequence_length across all beams for each batch.
end_token
`int32` scalar, the token that marks end of decoding.