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

Patch 2478 #2662

Merged
merged 5 commits into from
Nov 10, 2023
Merged

Patch 2478 #2662

merged 5 commits into from
Nov 10, 2023

Conversation

ahoblitz
Copy link
Contributor

@ahoblitz ahoblitz commented Nov 8, 2023

Fixes #2478

Description

Use nn.Transformer.generate_square_subsequent_mask when src_mask is None (Had to run to around ~30 epochs to get somewhat sensible output
Screenshot 2023-11-07 at 7 40 55 PM

Checklist

  • The issue that is being fixed is referred in the description (see above "Fixes #ISSUE_NUMBER")
  • Only one issue is addressed in this pull request
  • Labels from the issue that this PR is fixing are added to this pull request
  • No unnecessary issues are included into this pull request.

cc @pytorch/team-text-core @Nayef211 @sekyondaMeta @svekars @carljparker @NicolasHug @kit1980 @subramen

Copy link

pytorch-bot bot commented Nov 8, 2023

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/tutorials/2662

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 3d1cafc with merge base 16e4f2a (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

Copy link
Contributor

@albanD albanD left a comment

Choose a reason for hiding this comment

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

@drisspg can you double check this please?

@drisspg
Copy link
Contributor

drisspg commented Nov 8, 2023

I think I am okay with this but can you add some to the description saying that this is doing Causal Language Modeling and maybe a comment as to why we need this mask

@ahoblitz
Copy link
Contributor Author

ahoblitz commented Nov 9, 2023

@albanD @drisspg I added some text description to explain the need for generating a square causal mask for the sequence

@svekars svekars merged commit 57bad60 into pytorch:main Nov 10, 2023
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TransformerEncoder is not causal
5 participants