为复现: Multi-Task Learning Using Uncertainty to Weigh Losses for Scene Geometry and Semantics
(https://arxiv.org/pdf/1705.07115.pdf)
文章中:
原文章定义sigma为噪声,在原论文复现中(https://github.com/yaringal/multi-task-learning-example/blob/master/multi-task-learning-example.ipynb)直接是可学习的参数,见下图:
用pytorch复现的坑:
1、要用parameter,而不是定义常数torch.Tensor(torch.zeros(1))
from torch.nn import Parameter
self.log_cate = Parameter(t