scikit-rebate icon indicating copy to clipboard operation
scikit-rebate copied to clipboard

Problem with headers in VLSRelief and TurF during the fit

Open patriciamartinsconde opened this issue 5 years ago • 0 comments

Hi,

I run VLSRelief in a small dataset (100 features) in order to check if it run without any problems. However, after I rerun it in a large dataset (>160 000 features), at the end of the fit I got the following error:

from skrebate.vlsrelief import VLSRelief fs= VLSRelief(core_algorithm="ReliefF", n_features_to_select=1000, num_feature_subset=100, size_feature_subset=1630, verbose=True, n_jobs=-1) headers = list(X) fs.fit(np.array(X), y_encoded, headers)

Traceback (most recent call last): File "", line 1, in File "/Users/pmc/opt/anaconda3/lib/python3.7/site-packages/skrebate/vlsrelief.py", line 139, in fit self.headers_model = list(np.array(self.headers)[head_idx]) IndexError: index 101 is out of bounds for axis 0 with size 100

Also for TurF I got a similar error at the end of the run, but in this case already with 100 features. fs = TuRF(core_algorithm="ReliefF", n_features_to_select=10, pct=0.7, verbose=True, n_jobs=-1)

Traceback (most recent call last): File "", line 1, in File "/Users/pmc/opt/anaconda3/lib/python3.7/site-packages/skrebate/turf.py", line 166, in fit score_index = self.headers.index(i) ValueError: 'XYZ' is not in list

patriciamartinsconde avatar Apr 17 '20 08:04 patriciamartinsconde