pwtools.rbf.hyperopt.fit_opt

pwtools.rbf.hyperopt.fit_opt(points, values, method='de', what='pr', cv={'n_repeats': 1, 'n_splits': 5}, cv_kwds=None, opt_kwds={}, rbf_kwds={})[source]

Optimize Rbf’s hyper-parameter \(p\) or both \((p,r)\).

Use a cross validation error metric or the direct fit error if cv is None. Uses FitError.

Note: While we do have some defaults for initial guess or bounds, depending on the optimizer, you are strongly advised to set your own in opt_kwds.

Parameters:
Returns:

rbfi – Rbf instance initialized with points, values and found optimal p (and r).

Return type:

Rbf