|
|
1
4
我了解了收集函数的工作原理。
自
如果
所以公式是:
http://pytorch.org/docs/master/torch.html?highlight=gather#torch.gather |
|
|
2
3
只需在现有答案的基础上添加一个
例如,我们有这样的设置:
代码如下
输出:
|
|
|
Rotacional · 获取矩阵中的方向元素 1 年前 |
|
|
MJK · 我想知道为什么我的代码在PyTorch中使用编译时性能较低 2 年前 |
|
|
Elias E. · pytorch神经网络中的交叉熵损失。交叉熵() 8 年前 |
|
|
Wasi Ahmad · 参数维数对聚集函数的影响 8 年前 |