logbert
logbert copied to clipboard
test_size=68 should be either positive and smaller than the number of samples 34 or a float in the (0, 1) range
I run python logbert.py train
have error
logkey_trainset, logkey_validset, time_trainset, time_validset = train_test_split(logkey_seq_pairs,
......
ValueError: test_size=68 should be either positive and smaller than the number of samples 34 or a float in the (0, 1) range
I got that error too. Any helps?
I'm having another problem: ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 2 dimensions. The detected shape was (4855, 1) + inhomogeneous part.
I am having a problem with this "test_size=68 should be either positive and smaller than the number of samples 34 or a float in the (0, 1) range" was anybody able to solve this? any help would be appreciated
This worked for me:explicitly set dtype="object" for the np.array() call.
Found from:
https://stackoverflow.com/questions/67183501/setting-an-array-element-with-a-sequence-requested-array-has-an-inhomogeneous-sh