摘要:
前言 没有我想象中的难,毕竟站在前人的肩膀上,但还是遇到许多小困难,甚至一度想放弃 用时:两整天(白天) 目的:训练一个transformer模型,输入[1,2,3,4],能预测出[5,6,7,8] 最终效果:transformer model各层及维度符合预期,能train,predict还有一点 阅读全文
摘要:
indexes转one-hot https://stackoverflow.com/questions/65424771/how-to-convert-one-hot-vector-to-label-index-and-back-in-pytorch https://pytorch.org/docs 阅读全文
摘要:
ref: https://towardsdatascience.com/how-to-use-datasets-and-dataloader-in-pytorch-for-custom-text-data-270eed7f7c00 https://pytorch.org/tutorials/begi 阅读全文