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

Error in training (num_samples = 0 #17

Open
otori-bird opened this issue Jul 23, 2019 · 1 comment
Open

Error in training (num_samples = 0 #17

otori-bird opened this issue Jul 23, 2019 · 1 comment

Comments

@otori-bird
Copy link

otori-bird commented Jul 23, 2019

Traceback (most recent call last):
File "train.py", line 77, in
main(parser.parse_args())
File "train.py", line 43, in main
batch_size=args.batch_size,
File "G:\PYTHON\python3.5.4\lib\site-packages\torch\utils\data\dataloader.py", line 176, in init
sampler = RandomSampler(dataset)
File "G:\PYTHON\python3.5.4\lib\site-packages\torch\utils\data\sampler.py", line 66, in init
"value, but got num_samples={}".format(self.num_samples))
ValueError: num_samples should be a positive integer value, but got num_samples=0

torch version ==1.1.0
OS: windows10

should i specify some value in train.py?

@ktaebum
Copy link
Owner

ktaebum commented Jul 26, 2019

yes you must configure some command line argument
you can refer train.sh

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

2 participants