Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible Issue with train data documentation #7

Open
Skylion007 opened this issue Aug 11, 2016 · 2 comments
Open

Possible Issue with train data documentation #7

Skylion007 opened this issue Aug 11, 2016 · 2 comments

Comments

@Skylion007
Copy link

So I finally got the dataset created and have begun trying to train it. Unfortunately, I keep getting this error.

Traceback (most recent call last):
File "scripts/train.py", line 313, in
model, optimizer = one_epoch(args, model, optimizer, epoch, True)
File "scripts/train.py", line 288, in one_epoch
'epoch:{}\ttrain loss:{}'.format(epoch, sum_loss / num))
ZeroDivisionError: division by zero

Additionally, the train_batch script doesn't make any sense because you are using the same variable for the seed and GPU meaning that the latter calls would assume you have 8 GPUs on your machine which seems a little absurd? Or is that just the case and I am misreading the script?

@Skylion007
Copy link
Author

I narrowed down the issue. Apparently, it's prematurely terminating due to the if statement on line 199. I don't know why this would occur. The LMDBs appear to be generated properly and the shells/test_dataset.sh appears to complete just fine.

@Skylion007
Copy link
Author

Found the bug. It has to do with the create_dataset script. The dtype of keys is improperly set to 'b' when you probably meant to set it to binary. This makes the LMDB write to the same key over and over again and makes so that it only stores 256 values which isn't enough for training.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant