Skip to content

Commit

Permalink
workaround loky issue
Browse files Browse the repository at this point in the history
  • Loading branch information
guoci committed Dec 7, 2021
1 parent f507513 commit 0126398
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions easypqp/library.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,11 +211,10 @@ def predict(self, x):
def __repr__(self):
return str(self.get_params())


def lowess_iso_predictor(filename, x, y, xpred):
gsc = sklearn.model_selection.GridSearchCV(LowessIsoEstimator(None), {'lowess_frac': [0.01, 0.02, 0.04, 0.08]},
cv=sklearn.model_selection.KFold(4, shuffle=True, random_state=0),
n_jobs=-1)
n_jobs=min(os.cpu_count(), 61))

gsc.fit(x.reshape(-1, 1), y)
click.echo(f'Info: {filename}; Lowess fraction used: {gsc.best_params_["lowess_frac"]}.')
Expand Down

0 comments on commit 0126398

Please sign in to comment.