asyml / asyml/texar-pytorch

A bunch of doc issues

Open
#259 1 comment 0 reactions 2 assignees Claimed by @gpengzhi View on GitHub
priority: high topic: docs
Dominant language
Python
Stars
746
Forks
111
PR merge metrics
No merged PRs in 30d

Description

- [ ] `TransformerDecoder.forward`: where does `self.training` come from?
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/transformer_decoders.py#L448-L449

- [ ] All arguments should say their types **explicitly** in the docstring. E.g., what is the type of `infer_mode`? The [method signature](https://texar-pytorch.readthedocs.io/en/latest/code/modules.html#texar.torch.modules.TransformerDecoder.forward) is too dense to read for the type
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/transformer_decoders.py#L448-L449

- [ ] `TransformerDecoder.forward`: `start_tokens` and `end_token` are 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.
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/transformer_decoders.py#L353

- [ ] `RNNDecoderBase.forward`: An ordinary user (not developer) does not need to know `dynamic_decode`. It's confusing say `Please refer to ..` here. Say explicitly that it's needed only when one wants to over-write `forward` .. Also, we are using our own [dynamic_decode](https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/decoder_base.py#L374) -- should refer to here instead of `tf.contrib.seq2seq.dynamic_decode`
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/rnn_decoder_base.py#L104-L107

- [ ] `XLNetDecoder.forward`: Is `output` just a list of sampled tokens or `XLNetDecoderOutput`?
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/xlnet_decoder.py#L318-L320

- [ ] `"helper"` should be `"helper_type"`
https://github.com/asyml/texar-pytorch/blob/d17d502b50da1d95cb70435ed21c6603370ce76d/texar/torch/modules/decoders/xlnet_decoder.py#L313-L314

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.