genreXpose icon indicating copy to clipboard operation
genreXpose copied to clipboard

Runtime Error in classifier.py Line 25: cv = ShuffleSplit()

Open hexiaoling1994 opened this issue 8 years ago • 0 comments

I run genreXpose on WIndows 10, with Python 2.7.13 | Anaconda 4.3.0 (64-bit), sklern version = '0.18.1', but it seems have a problem.

Traceback (most recent call last): File "classifier.py", line 95, in train_avg, test_avg, cms = train_model(X, y, "ceps", plot=True) File "classifier.py", line 25, in train_model cv = ShuffleSplit(n=len(X), n_iterations=1, test_fraction=0.3, indices=True, random_state=0) TypeError: init() got an unexpected keyword argument 'indices'

It seems the sklern has updated all codes to python 3, one part of the file:

class ShuffleSplit(BaseShuffleSplit): ...... Examples -------- >>> from sklearn import cross_validation >>> rs = cross_validation.ShuffleSplit(4, n_iter=3, test_size=.25, random_state=0)

hexiaoling1994 avatar Apr 21 '17 10:04 hexiaoling1994