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

Fix Attention in seq2seq_translation_tutorial AttnDecoderRNN #2452

Merged
merged 7 commits into from
Jun 9, 2023

Conversation

QasimKhan5x
Copy link
Contributor

@QasimKhan5x QasimKhan5x commented Jun 8, 2023

Fixes #130

Description

  • Changes AttnDecoderRNN by replacing the previous attention mechanism with the method used by Bahdanau et al.
  • Changes the .png diagram that depicts the model to reflect the new one
  • Minor fixes like replacing encoder1 and attn_decoder1 with encoder and attn_decoder

Also, in the current tutorial, the visualizations clearly show wrong usage of attention. By merging this pull request, the correct visual display of feature importance via attention will be shown.

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

@pytorch-bot
Copy link

pytorch-bot bot commented Jun 8, 2023

🔗 Helpful Links

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

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

✅ No Failures

As of commit eefd16b:
💚 Looks good so far! There are no failures yet. 💚

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

@netlify
Copy link

netlify bot commented Jun 8, 2023

Deploy Preview for pytorch-tutorials-preview ready!

Name Link
🔨 Latest commit eefd16b
🔍 Latest deploy log https://app.netlify.com/sites/pytorch-tutorials-preview/deploys/64836538c950f700081cb74d
😎 Deploy Preview https://deploy-preview-2452--pytorch-tutorials-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions github-actions bot added module: torchtext docathon-h1-2023 A label for the docathon in H1 2023 medium and removed cla signed labels Jun 8, 2023
Copy link
Contributor

@Nayef211 Nayef211 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 updated diagram @QasimKhan5x

@svekars svekars merged commit a5376f7 into pytorch:main Jun 9, 2023
@QasimKhan5x QasimKhan5x deleted the seq2seq_fix branch June 10, 2023 01:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docathon-h1-2023 A label for the docathon in H1 2023 medium module: torchtext
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Port new seq2seq tutorial
4 participants