Skip to content

Commit

Permalink
net architecture fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
imelekhov committed Oct 13, 2019
1 parent 3f32895 commit aa0ef2f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion eval.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@

device = torch.device("cuda" if torch.cuda.is_available() else "cpu")

net.load_state_dict(torch.load(checkpoint_fname)['state_dict'])
net.load_state_dict(torch.load(checkpoint_fname, map_location=device)['state_dict'])
net = nn.DataParallel(net)
net.eval()
net = net.to(device)
Expand Down
2 changes: 0 additions & 2 deletions model/net.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,6 @@ def forward(self, x1, x2):
# do correlation
corr1 = self.corr(feat_top_pyr_trg, feat_top_pyr_src)
corr1 = self.l2norm(F.relu(corr1))
print(corr1.shape)
sys.exit()

b, c, h, w = corr1.size()
init_map = torch.FloatTensor(b, 2, h, w).zero_().to(self.device)
Expand Down

0 comments on commit aa0ef2f

Please sign in to comment.