from ~/CenterNet-master/src/lib/models/networks/large_hourglass.py
def forward(self, image):
# print('image shape', image.shape)
inter = self.pre(image)
outs = []
for ind in range(self.nstack):
kp_, cnv_ = self.kps[ind], self.cnvs[ind]
kp = kp_(inter)
cnv = cnv_(kp)
out = {}
for head in self.heads:
layer = self.__getattr__(head)[ind]
y = layer(cnv)
out[head] = y
outs.append(out)
if ind < self.nstack - 1:
inter = self.inters_[ind](inter) + self.cnvs_[ind](cnv)
inter = self.relu(inter)
inter = self.inters[ind](inter)
return outs # 最终的得到的outs是有两个字典(两次预测结果)的列表
why Hourglass-104 predict two output? and when compute the loss functions, take the average of two results
from ~/CenterNet-master/src/lib/models/networks/large_hourglass.py
why Hourglass-104 predict two output? and when compute the loss functions, take the average of two results