baitian963

调用 torch.nn.Embedding(m, n) 

m-语料库中字符的个数,例如【‘人’:1,‘们’:2】,m=2

n-需要将单个字符映射成多大维度的向量

 

其实就是一个训练好的m*n大小的矩阵,根据输入词对应的序号取出对应行的向量

 

详细可看https://blog.csdn.net/david0611/article/details/81090371

分类:

技术点:

相关文章:

  • 2022-01-13
  • 2021-12-15
  • 2022-12-23
  • 2021-08-21
  • 2021-08-06
  • 2021-08-06
猜你喜欢
  • 2021-08-06
  • 2022-01-25
  • 2022-12-23
  • 2021-04-08
  • 2022-12-23
  • 2021-06-02
  • 2021-08-06
相关资源
相似解决方案