Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed MHA documentation #883

Merged
merged 2 commits into from
Jul 15, 2020
Merged

Conversation

netw0rkf10w
Copy link
Contributor

No description provided.

@netw0rkf10w
Copy link
Contributor Author

@zhangguanheng66 You may want to check this out. Thanks.

@@ -110,7 +110,7 @@ def __init__(self, dropout=0.0, batch_first=False):
as `(batch, seq, feature)`. Default: ``False``

Examples::
>>> SDP = torchtext.nn.ScaledDotProduct(dropout=0.1)
>>> SDP = torchtext.nn.ScaledDotProduct(dropout=0.1, batch_first=True)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the example here, let's show the case without batch first.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zhangguanheng66 Fixed. Please review.

@codecov
Copy link

codecov bot commented Jul 15, 2020

Codecov Report

Merging #883 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #883   +/-   ##
=======================================
  Coverage   77.44%   77.44%           
=======================================
  Files          44       44           
  Lines        3055     3055           
=======================================
  Hits         2366     2366           
  Misses        689      689           
Impacted Files Coverage Δ
torchtext/nn/modules/multiheadattention.py 92.40% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b021bf9...ca2acd6. Read the comment docs.

Copy link
Contributor

@zhangguanheng66 zhangguanheng66 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution.

@zhangguanheng66 zhangguanheng66 merged commit 32bbb03 into pytorch:master Jul 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants