pylabel
pylabel copied to clipboard
how to split YOLO datasets to train/val. Not train/val/test
I tried code:
ds.splitter.GroupShuffleSplit(train_pct=0.7,val_pct=0.2,test_pct=0.0)
get
ValueError: train_size=0.0 should be either positive and smaller than the number of samples 376 or a float in the (0, 1) range
Why the param test_pct cannot be zero???
Hello @pizixie sorry for the confusion.
If you want to split into only 2 groups (train and test), then set val_pct to 0. It is not supported to set test_pct = 0. I will update the function with better documentation and error handling.