4ce9a9d078d41af1a960f0e5bf16e373f69d5117,open_seq2seq/decoders/rnn_decoders.py,BeamSearchRNNDecoderWithAttention,_decode,#BeamSearchRNNDecoderWithAttention#Any#,345
Before Change
dp_input_keep_prob = 1.0
dp_output_keep_prob = 1.0
if self.params["attention_type"].startswith("gnmt"):
residual_connections = False
wrap_to_multi_rnn = False
else:
After Change
residual_connections = self.params["decoder_use_skip_connections"]
// list of cells
self._decoder_cells = [
single_cell(cell_class=self.params["core_cell"],
cell_params=self.params.get("core_cell_params", {}),
dp_input_keep_prob=dp_input_keep_prob,
dp_output_keep_prob=dp_output_keep_prob,
// residual connections are added a little differently for GNMT
residual_connections=False if self.params[
"attention_type"].startswith(
"gnmt") else residual_connections,
) for _ in range(self.params["decoder_layers"])]
tiled_enc_outputs = tf.contrib.seq2seq.tile_batch(
encoder_outputs,
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances
Project Name: NVIDIA/OpenSeq2Seq
Commit Name: 4ce9a9d078d41af1a960f0e5bf16e373f69d5117
Time: 2018-06-13
Author: okuchaiev@nvidia.com
File Name: open_seq2seq/decoders/rnn_decoders.py
Class Name: BeamSearchRNNDecoderWithAttention
Method Name: _decode
Project Name: NVIDIA/OpenSeq2Seq
Commit Name: 4ce9a9d078d41af1a960f0e5bf16e373f69d5117
Time: 2018-06-13
Author: okuchaiev@nvidia.com
File Name: open_seq2seq/decoders/rnn_decoders.py
Class Name: RNNDecoderWithAttention
Method Name: _decode
Project Name: NVIDIA/OpenSeq2Seq
Commit Name: 4ce9a9d078d41af1a960f0e5bf16e373f69d5117
Time: 2018-06-13
Author: okuchaiev@nvidia.com
File Name: open_seq2seq/encoders/rnn_encoders.py
Class Name: GNMTLikeEncoderWithEmbedding
Method Name: _encode