Loading LibSVM train dataset returns different number of features than test dataset

Viewed 28

I am loading LibSVM official dataset and the train and test dataset have different number of features. This is an example:

X_train, y_train = load_svmlight_file(f"./a5a")
X_train.shape
(6414, 122)

y_train.shape
(6414,)

X_train, y_train = load_svmlight_file(f"./a5a.t")
X_train.shape
(26147, 123)

y_train.shape
(26147,) 

Anyone knows what is happening here? I have not found an explanation for this phenomenon either by looking at the documentation of the dataset itself or in the documentation of the sklearn method.

0 Answers
Related