Nov3
Joseph 2020-10-27 04:42:52 +05:30
parent 11f5b8bcc2
commit a99cb674b6
1 changed files with 1 additions and 1 deletions

View File

@ -667,7 +667,7 @@ class FastRCNNOutputLayers(nn.Module):
new_means[index] = torch.tensor(item).mean(dim=0)
# Update the MUs
for i, mean in enumerate(self.means):
if(mean) is not None:
if(mean) is not None and new_means[i] is not None:
self.means[i] = self.clustering_momentum * mean + \
(1 - self.clustering_momentum) * new_means[i]