org.platanios.tensorflow.api.ops.seq2seq.decoders
Final outputs returned by the beam search after all decoding is finished.
Final outputs returned by the beam search after all decoding is finished.
Tensor of shape [batchSize, T, beamWidth]
(or [T, batchSize, beamWidth]
,
if outputTimeMajor == true
) containing the final prediction IDs. The search states are
ordered from best to worst.
State of the beam search at the end of decoding.
Maybe converts the provided tensor structure from batches by beams into batches of beams, by merging them accordingly.
Maybe converts the provided tensor structure from batches by beams into batches of beams, by merging them accordingly.
More precisely, value
consists of tensors with shape [batchSize * beamWidth] ++ ...
and this method reshapes
them into tensors with shape [batchSize, beamWidth] ++ ...
.
Value to reshape.
Depth shape of the value.
Reshaped state.
InvalidArgumentException
If value
is of an unsupported type, or if it contains any tensors of unknown
rank, or if, after reshaping, the new tensor is not shaped
[batchSize, beamWidth] ++ ...
(assuming that both batchSize
and beamWidth
are known statically).