reiinakano/xcessiv

Error with tuple hyperparameters

Open

#57 opened on Feb 5, 2018

View on GitHub
 (2 comments) (0 reactions) (0 assignees)Python (110 forks)batch import
bughelp wanted

Repository metrics

Stars
 (1,267 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

Hello @reiinakano

I have an issue with tuple hyperparameters. I think the bracket are ommited during the training

from gplearn.genetic import SymbolicRegressor base_learner = SymbolicRegressor(random_state=8,n_jobs=6)

params = {'function_set':('sqrt','add', 'sub', 'mul', 'div','max','min','log'), 'const_range':(-30, 280), 'init_depth':(6, 13) 'population_size': 150, 'generations': 600, 'stopping_criteria': 0.001, 'p_crossover': 0.45, 'p_subtree_mutation': 0.15, 'p_hoist_mutation': 0.15, 'p_point_mutation': 0.25, 'max_samples': 0.85, 'metric': 'rmse', 'parsimony_coefficient': 0.0002}

Traceback (most recent call last): File "/root/anaconda3/lib/python3.6/site-packages/xcessiv/rqtasks.py", line 135, in generate_meta_features est = est.fit(X_train, y_train) File "/root/anaconda3/lib/python3.6/site-packages/gplearn/genetic.py", line 366, in fit raise ValueError('const_range should be a tuple with length two.') ValueError: const_range should be a tuple with length two.

Contributor guide