leopiney / deep-forest

An on going implementation of the gcForest algorithm
MIT License
194 stars 58 forks source link

IndexError: too many indices for array #5

Open Mrxuefei opened 7 years ago

Mrxuefei commented 7 years ago

Thanks for your implementation! When I want to train my model,I have a x_train(32300,92160) y_train(32300,1),but I got an error:

- Scanning and fitting for X ((32300,)) and y ((32300,)) started - Window shape: [1, 23040] Total windows: 69121 Traceback (most recent call last): File "gcForest_fer.py", line 71, in mgc_forest.fit(x_train, y_train) File "/home/wangjian/wj/deep_forest.py", line 68, in fit for mgs in self.mgs_instances File "/home/wangjian/wj/deep_forest.py", line 191, in scan sliced_X, sliced_y = self.slices(X, y) File "/home/wangjian/wj/deep_forest.py", line 154, in slices windows_slices_list = X[(slice(None),) + axis_slices] IndexError: too many indices for array. Can you tell me why I am wrong? Thank you!
leopiney commented 7 years ago

Hi @Mrxuefei

I've just merged a PR with some major improvements on the MGS algorithm. Can you try again with the latest version of the code?

Kind regards,