-
Notifications
You must be signed in to change notification settings - Fork 113
Description
-
TransformerDecoder.forward: where doesself.trainingcome from?
texar-pytorch/texar/torch/modules/decoders/transformer_decoders.py
Lines 448 to 449 in d17d502
infer_mode (optional): If not `None`, overrides mode given by :attr:`self.training`. -
All arguments should say their types explicitly in the docstring. E.g., what is the type of
infer_mode? The method signature is too dense to read for the type
texar-pytorch/texar/torch/modules/decoders/transformer_decoders.py
Lines 448 to 449 in d17d502
infer_mode (optional): If not `None`, overrides mode given by :attr:`self.training`. -
TransformerDecoder.forward:start_tokensandend_tokenare mentioned but they are not explained in the argument docstring, and there is not explicit pointer that tells users where they can find the explanation.
Arguments :attr:`(start_tokens, end_token)` are -
RNNDecoderBase.forward: An ordinary user (not developer) does not need to knowdynamic_decode. It's confusing sayPlease refer to ..here. Say explicitly that it's needed only when one wants to over-writeforward.. Also, we are using our own dynamic_decode -- should refer to here instead oftf.contrib.seq2seq.dynamic_decode
texar-pytorch/texar/torch/modules/decoders/rnn_decoder_base.py
Lines 104 to 107 in d17d502
Implementation calls :meth:`initialize` once and :meth:`step` repeatedly on the decoder object. Please refer to `tf.contrib.seq2seq.dynamic_decode <https://www.tensorflow.org/api_docs/python/tf/contrib/seq2seq/dynamic_decode>`_. -
XLNetDecoder.forward: Isoutputjust a list of sampled tokens orXLNetDecoderOutput?
texar-pytorch/texar/torch/modules/decoders/xlnet_decoder.py
Lines 318 to 320 in d17d502
:returns: A tuple of `(output, new_memory)`: - **`output`**: The sampled tokens as a list of integers. - **`new_memory`**: The memory of the sampled tokens. -
"helper"should be"helper_type"
texar-pytorch/texar/torch/modules/decoders/xlnet_decoder.py
Lines 313 to 314 in d17d502
helper: Type (or name of the type) of any sub-class of :class:`~texar.torch.modules.Helper`.