Beam Search Decoder outputs -1 as prediction (how is this possible?)
did you try using the FinalBeamSearchDecoderOutput instead of dynamic decode ? https://www.tensorflow.org/api_docs/python/tf/contrib/seq2seq/FinalBeamSearchDecoderOutput
Is there any update on this? @nave01314 Did you figure out how to resolve the error? I'm running into the same issue...
Is there any update on this? @nave01314 Did you figure out how to resolve the error? I'm running into the same issue...
It looks like dynamic_decode() pads the output with -1 outside of the valid length. The lengths are returned by dynamic_decode() as the third variable, so you can use that to mask the output or only use the valid parts of each decoded sequence.