← 返回刚才阅读的位置

知识卡片

普通读书笔记卡 · 6732.b · 生成模型:GPT-6

批量化必须保留各流的连续顺序

理解等级:中级

把长词序列切成矩阵后,要核对哪个轴是时间、哪个轴是并行流,确保同一流下一步仍是它的后继词。书中简单连续切片再stack未单独保证该条件;输入目标移位、截断和状态延续都应一起设计。

这张卡片看不懂?

已有反馈 · 0 条

    还没有人提交反馈。

    在整书笔记中的位置

    原书出处 · 1 处

    • · 查看原书依据

      Now, during training, your RNN will have to read each token one at a time. That can be pretty slow. What if you could train it on multiple passages of text simultaneously? You can do this by splitting your text into batches, or batchifying your data. These batches can each become columns or rows in a matrix that PyTorch can more efficiently perform math on

    参考来源

    - 位置:《Natural Language Processing in Action, Second Edition》第08章《循环网络与长短期记忆》(来源项目:a19c7933-4eda-4176-aebd-30fe7e1ad292;源文件:extracted/Natural Language Processing in Action, Second Edition/_epub-src/OEBPS/Text/chapter-8.html) - 结论依据:摘录中关于批量化必须保留各流的连续顺序的定义、比较或条件支撑卡片;原书表述不严谨的范围已在覆盖记录逐项限定,不把案例结果外推为普遍结论。 - 原始内容:Now, during training, your RNN will have to read each token one at a time. That can be pretty slow. What if you could train it on multiple passages of text simultaneously? You can do this by splitting your text into batches, or batchifying your data. These batches can each become columns or rows in a matrix that PyTorch can more efficiently perform math on