René's URL Explorer Experiment


Title: NLP-Interview-Notes/DeepLearningAlgorithm/transformer at main · xebin/NLP-Interview-Notes · GitHub

Open Graph Title: NLP-Interview-Notes/DeepLearningAlgorithm/transformer at main · xebin/NLP-Interview-Notes

X Title: NLP-Interview-Notes/DeepLearningAlgorithm/transformer at main · xebin/NLP-Interview-Notes

Description: 该仓库主要记录 NLP 算法工程师相关的面试题. Contribute to xebin/NLP-Interview-Notes development by creating an account on GitHub.

Open Graph Description: 该仓库主要记录 NLP 算法工程师相关的面试题. Contribute to xebin/NLP-Interview-Notes development by creating an account on GitHub.

X Description: 该仓库主要记录 NLP 算法工程师相关的面试题. Contribute to xebin/NLP-Interview-Notes development by creating an account on GitHub.

Opengraph URL: https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/tree/*name(/*path)
route-controllerfiles
route-actiondisambiguate
fetch-noncev2:59288161-7931-f115-e8a6-096995bacc6e
current-catalog-service-hashf3abb0cc802f3d7b95fc8762b94bdcb13bf39634c40c357301c4aa1d67a256fb
request-idAD66:188FE8:3EEFFE6:58D70A4:6A4FAB33
html-safe-nonce7f407a5ac8d0b23e13790a996f8c9686d95418ec35ee8c69c3752573e03514bc
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRDY2OjE4OEZFODozRUVGRkU2OjU4RDcwQTQ6NkE0RkFCMzMiLCJ2aXNpdG9yX2lkIjoiNDMxNzIzMjE2NjYwMDQ4NjkxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacff237f0ee2f4c5d04a777dfcdcc364d2f0f1fcad1122c676a7cecfe9eb4fe8c3
hovercard-subject-tagrepository:529608295
github-keyboard-shortcutsrepository,source-code,file-tree,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///files/disambiguate
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer
twitter:imagehttps://opengraph.githubassets.com/26563a455d4154d5f17c7cfc0c3990e3dbbc7d9d22d90bb10c1d86c06ec0eeae/xebin/NLP-Interview-Notes
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/26563a455d4154d5f17c7cfc0c3990e3dbbc7d9d22d90bb10c1d86c06ec0eeae/xebin/NLP-Interview-Notes
og:image:alt该仓库主要记录 NLP 算法工程师相关的面试题. Contribute to xebin/NLP-Interview-Notes development by creating an account on GitHub.
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noneb92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9
turbo-cache-controlno-cache
go-importgithub.com/xebin/NLP-Interview-Notes git https://github.com/xebin/NLP-Interview-Notes.git
octolytics-dimension-user_id8914647
octolytics-dimension-user_loginxebin
octolytics-dimension-repository_id529608295
octolytics-dimension-repository_nwoxebin/NLP-Interview-Notes
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forktrue
octolytics-dimension-repository_parent_id341198747
octolytics-dimension-repository_parent_nwokm1994/NLP-Interview-Notes
octolytics-dimension-repository_network_root_id341198747
octolytics-dimension-repository_network_root_nwokm1994/NLP-Interview-Notes
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release4b249b445842943ed31549e027f57a8ade9881ed
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fxebin%2FNLP-Interview-Notes%2Ftree%2Fmain%2FDeepLearningAlgorithm%2Ftransformer
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fxebin%2FNLP-Interview-Notes%2Ftree%2Fmain%2FDeepLearningAlgorithm%2Ftransformer
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Ffiles%2Fdisambiguate&source=header-repo&source_repo=xebin%2FNLP-Interview-Notes
Reloadhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer
Reloadhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer
Reloadhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer
xebin https://github.com/xebin
NLP-Interview-Noteshttps://github.com/xebin/NLP-Interview-Notes
km1994/NLP-Interview-Noteshttps://github.com/km1994/NLP-Interview-Notes
Notifications https://github.com/login?return_to=%2Fxebin%2FNLP-Interview-Notes
Fork 0 https://github.com/login?return_to=%2Fxebin%2FNLP-Interview-Notes
Star 1 https://github.com/login?return_to=%2Fxebin%2FNLP-Interview-Notes
Code https://github.com/xebin/NLP-Interview-Notes
Pull requests 0 https://github.com/xebin/NLP-Interview-Notes/pulls
Actions https://github.com/xebin/NLP-Interview-Notes/actions
Projects https://github.com/xebin/NLP-Interview-Notes/projects
Security and quality 0 https://github.com/xebin/NLP-Interview-Notes/security
Insights https://github.com/xebin/NLP-Interview-Notes/pulse
Code https://github.com/xebin/NLP-Interview-Notes
Pull requests https://github.com/xebin/NLP-Interview-Notes/pulls
Actions https://github.com/xebin/NLP-Interview-Notes/actions
Projects https://github.com/xebin/NLP-Interview-Notes/projects
Security and quality https://github.com/xebin/NLP-Interview-Notes/security
Insights https://github.com/xebin/NLP-Interview-Notes/pulse
https://github.com/xebin/NLP-Interview-Notes
NLP-Interview-Noteshttps://github.com/xebin/NLP-Interview-Notes/tree/main
DeepLearningAlgorithmhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm
Historyhttps://github.com/xebin/NLP-Interview-Notes/commits/main/DeepLearningAlgorithm/transformer
https://github.com/xebin/NLP-Interview-Notes/commits/main/DeepLearningAlgorithm/transformer
NLP-Interview-Noteshttps://github.com/xebin/NLP-Interview-Notes/tree/main
DeepLearningAlgorithmhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm
..https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm
imghttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer/img
imghttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer/img
readme.mdhttps://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/readme.md
readme.mdhttps://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/readme.md
readme.mdhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#readme
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#关于transformer那些你不知道的事
https://arxiv.org/pdf/1706.03762.pdfhttps://arxiv.org/pdf/1706.03762.pdf
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/Transformer.png
【关于Transformer】那些你不知道的事https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#%E5%85%B3%E4%BA%8Etransformer%E9%82%A3%E4%BA%9B%E4%BD%A0%E4%B8%8D%E7%9F%A5%E9%81%93%E7%9A%84%E4%BA%8B
一、动机篇https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#%E4%B8%80%E5%8A%A8%E6%9C%BA%E7%AF%87
1.1 为什么要有 Transformer?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#11-%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81%E6%9C%89-transformer
1.2 Transformer 作用是什么?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#12-transformer-%E4%BD%9C%E7%94%A8%E6%98%AF%E4%BB%80%E4%B9%88
二、整体结构篇https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#%E4%BA%8C%E6%95%B4%E4%BD%93%E7%BB%93%E6%9E%84%E7%AF%87
2.1 Transformer 整体结构是怎么样?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#21-transformer-%E6%95%B4%E4%BD%93%E7%BB%93%E6%9E%84%E6%98%AF%E6%80%8E%E4%B9%88%E6%A0%B7
2.2 Transformer-encoder 结构怎么样?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#22-transformer-encoder-%E7%BB%93%E6%9E%84%E6%80%8E%E4%B9%88%E6%A0%B7
2.3 Transformer-decoder 结构怎么样?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#23-transformer-decoder-%E7%BB%93%E6%9E%84%E6%80%8E%E4%B9%88%E6%A0%B7
三、模块篇https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#%E4%B8%89%E6%A8%A1%E5%9D%97%E7%AF%87
3.1 self-attention 模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#31-self-attention-%E6%A8%A1%E5%9D%97
3.1.1 传统 attention 是什么?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#311-%E4%BC%A0%E7%BB%9F-attention-%E6%98%AF%E4%BB%80%E4%B9%88
3.1.2 为什么 会有self-attention?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#312-%E4%B8%BA%E4%BB%80%E4%B9%88-%E4%BC%9A%E6%9C%89self-attention
3.1.3 self-attention 的核心思想是什么?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#313-self-attention-%E7%9A%84%E6%A0%B8%E5%BF%83%E6%80%9D%E6%83%B3%E6%98%AF%E4%BB%80%E4%B9%88
3.1.4 self-attention 的目的是什么?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#314-self-attention-%E7%9A%84%E7%9B%AE%E7%9A%84%E6%98%AF%E4%BB%80%E4%B9%88
3.1.5 self-attention 的怎么计算的?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#315-self-attention-%E7%9A%84%E6%80%8E%E4%B9%88%E8%AE%A1%E7%AE%97%E7%9A%84
3.1.6 self-attention 为什么Q和K使用不同的权重矩阵生成,为何不能使用同一个值进行自身的点乘?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#316-self-attention-%E4%B8%BA%E4%BB%80%E4%B9%88q%E5%92%8Ck%E4%BD%BF%E7%94%A8%E4%B8%8D%E5%90%8C%E7%9A%84%E6%9D%83%E9%87%8D%E7%9F%A9%E9%98%B5%E7%94%9F%E6%88%90%E4%B8%BA%E4%BD%95%E4%B8%8D%E8%83%BD%E4%BD%BF%E7%94%A8%E5%90%8C%E4%B8%80%E4%B8%AA%E5%80%BC%E8%BF%9B%E8%A1%8C%E8%87%AA%E8%BA%AB%E7%9A%84%E7%82%B9%E4%B9%98
3.1.7 为什么采用点积模型的 self-attention 而不采用加性模型?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#317-%E4%B8%BA%E4%BB%80%E4%B9%88%E9%87%87%E7%94%A8%E7%82%B9%E7%A7%AF%E6%A8%A1%E5%9E%8B%E7%9A%84-self-attention-%E8%80%8C%E4%B8%8D%E9%87%87%E7%94%A8%E5%8A%A0%E6%80%A7%E6%A8%A1%E5%9E%8B
3.1.8 Transformer 中在计算 self-attention 时为什么要scaled dot product? 即 除以 $\sqrt{d}$?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#318-transformer-%E4%B8%AD%E5%9C%A8%E8%AE%A1%E7%AE%97-self-attention-%E6%97%B6%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81scaled-dot-product-%E5%8D%B3-%E9%99%A4%E4%BB%A5-sqrtd
3.1.9 self-attention 如何解决长距离依赖问题?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#319-self-attention-%E5%A6%82%E4%BD%95%E8%A7%A3%E5%86%B3%E9%95%BF%E8%B7%9D%E7%A6%BB%E4%BE%9D%E8%B5%96%E9%97%AE%E9%A2%98
3.1.10 self-attention 如何并行化?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#3110-self-attention-%E5%A6%82%E4%BD%95%E5%B9%B6%E8%A1%8C%E5%8C%96
3.1.11 为什么用双线性点积模型(即Q,K两个向量)https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#3111-%E4%B8%BA%E4%BB%80%E4%B9%88%E7%94%A8%E5%8F%8C%E7%BA%BF%E6%80%A7%E7%82%B9%E7%A7%AF%E6%A8%A1%E5%9E%8B%E5%8D%B3qk%E4%B8%A4%E4%B8%AA%E5%90%91%E9%87%8F
3.2 multi-head attention 模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#32-multi-head-attention-%E6%A8%A1%E5%9D%97
3.2.1 multi-head attention 的思路是什么样?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#321-multi-head-attention-%E7%9A%84%E6%80%9D%E8%B7%AF%E6%98%AF%E4%BB%80%E4%B9%88%E6%A0%B7
3.2.2 multi-head attention 的步骤是什么样?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#322-multi-head-attention-%E7%9A%84%E6%AD%A5%E9%AA%A4%E6%98%AF%E4%BB%80%E4%B9%88%E6%A0%B7
3.2.3 Transformer为何使用多头注意力机制?(为什么不使用一个头)https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#323-transformer%E4%B8%BA%E4%BD%95%E4%BD%BF%E7%94%A8%E5%A4%9A%E5%A4%B4%E6%B3%A8%E6%84%8F%E5%8A%9B%E6%9C%BA%E5%88%B6%E4%B8%BA%E4%BB%80%E4%B9%88%E4%B8%8D%E4%BD%BF%E7%94%A8%E4%B8%80%E4%B8%AA%E5%A4%B4
3.2.4 多头机制为什么有效?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#324-%E5%A4%9A%E5%A4%B4%E6%9C%BA%E5%88%B6%E4%B8%BA%E4%BB%80%E4%B9%88%E6%9C%89%E6%95%88
3.2.5 为什么在进行多头注意力的时候需要对每个head进行降维?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#325-%E4%B8%BA%E4%BB%80%E4%B9%88%E5%9C%A8%E8%BF%9B%E8%A1%8C%E5%A4%9A%E5%A4%B4%E6%B3%A8%E6%84%8F%E5%8A%9B%E7%9A%84%E6%97%B6%E5%80%99%E9%9C%80%E8%A6%81%E5%AF%B9%E6%AF%8F%E4%B8%AAhead%E8%BF%9B%E8%A1%8C%E9%99%8D%E7%BB%B4
3.2.6 multi-head attention 代码介绍https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#326-multi-head-attention-%E4%BB%A3%E7%A0%81%E4%BB%8B%E7%BB%8D
3.3 位置编码(Position encoding)模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#33-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding%E6%A8%A1%E5%9D%97
3.3.1 为什么要 加入 位置编码(Position encoding) ?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#331-%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81-%E5%8A%A0%E5%85%A5-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding-
3.3.2 位置编码(Position encoding)的思路是什么 ?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#332-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding%E7%9A%84%E6%80%9D%E8%B7%AF%E6%98%AF%E4%BB%80%E4%B9%88-
3.3.3 位置编码(Position encoding)的作用是什么 ?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#333-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding%E7%9A%84%E4%BD%9C%E7%94%A8%E6%98%AF%E4%BB%80%E4%B9%88-
3.3.4 位置编码(Position encoding)的步骤是什么 ?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#334-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding%E7%9A%84%E6%AD%A5%E9%AA%A4%E6%98%AF%E4%BB%80%E4%B9%88-
3.3.5 Position encoding为什么选择相加而不是拼接呢?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#335-position-encoding%E4%B8%BA%E4%BB%80%E4%B9%88%E9%80%89%E6%8B%A9%E7%9B%B8%E5%8A%A0%E8%80%8C%E4%B8%8D%E6%98%AF%E6%8B%BC%E6%8E%A5%E5%91%A2
3.3.6 Position encoding和 Position embedding的区别?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#336-position-encoding%E5%92%8C-position-embedding%E7%9A%84%E5%8C%BA%E5%88%AB
3.3.7 为何17年提出Transformer时采用的是 Position Encoder 而不是Position Embedding?而Bert却采用的是 Position Embedding ?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#337-%E4%B8%BA%E4%BD%9517%E5%B9%B4%E6%8F%90%E5%87%BAtransformer%E6%97%B6%E9%87%87%E7%94%A8%E7%9A%84%E6%98%AF-position-encoder--%E8%80%8C%E4%B8%8D%E6%98%AFposition-embedding%E8%80%8Cbert%E5%8D%B4%E9%87%87%E7%94%A8%E7%9A%84%E6%98%AF-position-embedding-
3.3.8 位置编码(Position encoding)的代码介绍https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#338-%E4%BD%8D%E7%BD%AE%E7%BC%96%E7%A0%81position-encoding%E7%9A%84%E4%BB%A3%E7%A0%81%E4%BB%8B%E7%BB%8D
3.4 残差模块模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#34-%E6%AE%8B%E5%B7%AE%E6%A8%A1%E5%9D%97%E6%A8%A1%E5%9D%97
3.4.1 为什么要 加入 残差模块?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#341-%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81-%E5%8A%A0%E5%85%A5-%E6%AE%8B%E5%B7%AE%E6%A8%A1%E5%9D%97
3.5 Layer normalization 模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#35-layer-normalization-%E6%A8%A1%E5%9D%97
3.5.1 为什么要 加入 Layer normalization 模块?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#351-%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81-%E5%8A%A0%E5%85%A5-layer-normalization-%E6%A8%A1%E5%9D%97
3.5.2 Layer normalization 模块的是什么?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#352-layer-normalization-%E6%A8%A1%E5%9D%97%E7%9A%84%E6%98%AF%E4%BB%80%E4%B9%88
3.5.3 Batch normalization 和 Layer normalization 的区别?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#353-batch-normalization-%E5%92%8C-layer-normalization-%E7%9A%84%E5%8C%BA%E5%88%AB
3.5.4 Transformer 中为什么要舍弃 Batch normalization 改用 Layer normalization 呢?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#354-transformer-%E4%B8%AD%E4%B8%BA%E4%BB%80%E4%B9%88%E8%A6%81%E8%88%8D%E5%BC%83-batch-normalization-%E6%94%B9%E7%94%A8-layer-normalization-%E5%91%A2
3.5.5 Layer normalization 模块代码介绍https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#355--layer-normalization-%E6%A8%A1%E5%9D%97%E4%BB%A3%E7%A0%81%E4%BB%8B%E7%BB%8D
3.6 Mask 模块https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#36-mask-%E6%A8%A1%E5%9D%97
3.6.1 什么是 Mask?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#361-%E4%BB%80%E4%B9%88%E6%98%AF-mask
3.6.2 Transformer 中用到 几种 Mask?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#362-transformer-%E4%B8%AD%E7%94%A8%E5%88%B0-%E5%87%A0%E7%A7%8D-mask
3.6.3 能不能介绍一下 Transformer 中用到几种 Mask?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#363-%E8%83%BD%E4%B8%8D%E8%83%BD%E4%BB%8B%E7%BB%8D%E4%B8%80%E4%B8%8B-transformer-%E4%B8%AD%E7%94%A8%E5%88%B0%E5%87%A0%E7%A7%8D-mask
3.7 Feed forward network (FFN)https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#37-feed-forward-network-ffn
3.7.1 Feed forward network (FFN)的作用?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#371-feed-forward-network-ffn%E7%9A%84%E4%BD%9C%E7%94%A8
3.8 GELUhttps://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#38-gelu
3.8.1 GELU原理?相比RELU的优点?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#381-gelu%E5%8E%9F%E7%90%86%E7%9B%B8%E6%AF%94relu%E7%9A%84%E4%BC%98%E7%82%B9
3.9 Transformer的非线性来自于哪里?https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#39-transformer%E7%9A%84%E9%9D%9E%E7%BA%BF%E6%80%A7%E6%9D%A5%E8%87%AA%E4%BA%8E%E5%93%AA%E9%87%8C
参考https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#%E5%8F%82%E8%80%83
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#一动机篇
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#11-为什么要有-transformer
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#12-transformer-作用是什么
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#二整体结构篇
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#21-transformer-整体结构是怎么样
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200623092901.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200623093042.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200623093217.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#22-transformer-encoder-结构怎么样
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624080740.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624081753.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#23-transformer-decoder-结构怎么样
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624083258.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#三模块篇
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#31-self-attention-模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#311-传统-attention-是什么
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625085139.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625085922.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625090454.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20201009163936.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20201009164019.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20201009164053.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625093537.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625095930.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#312-为什么-会有self-attention
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#313-self-attention-的核心思想是什么
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#314-self-attention-的目的是什么
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#315-self-attention-的怎么计算的
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624084515.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625082324.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#316-self-attention-为什么q和k使用不同的权重矩阵生成为何不能使用同一个值进行自身的点乘
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#317-为什么采用点积模型的-self-attention-而不采用加性模型
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#318-transformer-中在计算-self-attention-时为什么要scaled-dot-product-即-除以-sqrtd
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20201222225938.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20201222230028.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20201222225802.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#319-self-attention-如何解决长距离依赖问题
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200626120834.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200626122726.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#3110-self-attention-如何并行化
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#3111-为什么用双线性点积模型即qk两个向量
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#32-multi-head-attention-模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#321-multi-head-attention-的思路是什么样
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#322-multi-head-attention-的步骤是什么样
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200625101229.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624090026.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624090034.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20200625101800.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/v2-595ce4ebf9b3fccb479f7d234190af35_b.gif
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#323-transformer为何使用多头注意力机制为什么不使用一个头
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#324-多头机制为什么有效
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#325-为什么在进行多头注意力的时候需要对每个head进行降维
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#326-multi-head-attention-代码介绍
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#33-位置编码position-encoding模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#331-为什么要-加入-位置编码position-encoding-
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#332-位置编码position-encoding的思路是什么-
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#333-位置编码position-encoding的作用是什么-
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#334-位置编码position-encoding的步骤是什么-
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200625103634.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/20200624090357.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#335-position-encoding为什么选择相加而不是拼接呢
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#336-position-encoding和-position-embedding的区别
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#337-为何17年提出transformer时采用的是-position-encoder--而不是position-embedding而bert却采用的是-position-embedding-
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#338-位置编码position-encoding的代码介绍
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#34-残差模块模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#341-为什么要-加入-残差模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#35-layer-normalization-模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#351-为什么要-加入-layer-normalization-模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#352-layer-normalization-模块的是什么
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#353-batch-normalization-和-layer-normalization-的区别
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200625110603.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/QQ%E6%88%AA%E5%9B%BE20200625110706.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#354-transformer-中为什么要舍弃-batch-normalization-改用-layer-normalization-呢
Transformer代码+面试细节https://zhuanlan.zhihu.com/p/438634058
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#355--layer-normalization-模块代码介绍
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#36-mask-模块
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#361-什么是-mask
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#362-transformer-中用到-几种-mask
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#363-能不能介绍一下-transformer-中用到几种-mask
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20210128073806.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20210128074033.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20210128074300.png
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#37-feed-forward-network-ffn
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#371-feed-forward-network-ffn的作用
Transformer代码+面试细节https://zhuanlan.zhihu.com/p/438634058
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#38-gelu
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#381-gelu原理相比relu的优点
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20211203094546.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20211203095003.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20211203095438.png
https://github.com/xebin/NLP-Interview-Notes/blob/main/DeepLearningAlgorithm/transformer/img/%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_20211203095511.png
Transformer代码+面试细节https://zhuanlan.zhihu.com/p/438634058
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#39-transformer的非线性来自于哪里
https://github.com/xebin/NLP-Interview-Notes/tree/main/DeepLearningAlgorithm/transformer#参考
Transformer理论源码细节详解https://zhuanlan.zhihu.com/p/106867810
论文笔记:Attention is all you need(Transformer)https://zhuanlan.zhihu.com/p/51089880
深度学习-论文阅读-Transformer-20191117https://zhuanlan.zhihu.com/p/92234185
Transform详解(超详细) Attention is all you need论文https://zhuanlan.zhihu.com/p/63191028
目前主流的attention方法都有哪些?https://www.zhihu.com/question/68482809/answer/597944559
transformer三部曲https://zhuanlan.zhihu.com/p/85612521
Transformer代码+面试细节https://zhuanlan.zhihu.com/p/438634058
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.