Skip to content

Commit

Permalink
Merge branch 'master' of github.com:harvardnlp/sent-conv-torch
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffreyling committed Aug 15, 2017
2 parents 6e58188 + 33f9a0c commit d61ded0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -253,13 +253,15 @@ function load_data()
opt.has_dev = 1
dev = f:read('dev'):all()
dev_label = f:read('dev_label'):all()
assert(torch.max(dev_label) <= opt.num_classes, 'more valid classes than train')
end
if f:read('test'):dataspaceSize()[1] == 0 then
opt.has_test = 0
else
opt.has_test = 1
test = f:read('test'):all()
test_label = f:read('test_label'):all()
assert(torch.max(test_label) <= opt.num_classes, 'more test classes than train')
end
print('data loaded!')

Expand Down

0 comments on commit d61ded0

Please # to comment.