Skip to content

Commit

Permalink
fix for giannisnik#6
Browse files Browse the repository at this point in the history
Accuracy = 0 as a result of recent PyTorch changes. See here for info: pytorch/pytorch#5411
  • Loading branch information
robd2 committed Sep 14, 2018
1 parent d641f98 commit e77488f
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 1 deletion.
Binary file added kcnn/__pycache__/graph_kernels.cpython-36.pyc
Binary file not shown.
Binary file added kcnn/__pycache__/model.cpython-36.pyc
Binary file not shown.
Binary file added kcnn/__pycache__/nystrom.cpython-36.pyc
Binary file not shown.
Binary file added kcnn/__pycache__/utils.cpython-36.pyc
Binary file not shown.
Binary file added kcnn/checkpoint/kcnn/checkpoint.pth
Binary file not shown.
Binary file added kcnn/checkpoint/kcnn/model_best.pth
Binary file not shown.
2 changes: 1 addition & 1 deletion kcnn/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def main():

criterion = nn.CrossEntropyLoss()

evaluation = lambda output, target: torch.sum(output.eq(target)) / target.size()[0]
evaluation = lambda output, target: float (torch.sum(output.eq(target))) / float (target.size()[0])

lr = args.lr
lr_step = (args.lr-args.lr*args.lr_decay)/(args.epochs*args.schedule[1] - args.epochs*args.schedule[0])
Expand Down

0 comments on commit e77488f

Please sign in to comment.