摘要: import torch import torch.nn.functional as F # 一个形状为 (batch_size, seq_len, feature_dim) 的张量(矩阵) x # 两个样本, 每个样本3 个词语长度,每个词语编码为4维 x = torch.randn(2, 3, 阅读全文
posted @ 2026-07-28 23:44 Marksion 阅读(5) 评论(0) 推荐(0)