I'm working with a recursive feature elimination (RFE) pipeline:
from sklearn.feature_selection import RFE
c_GAUSS = GaussianProcessClassifier()
rfe = RFE(estimator=c_GAUSS)
However, I get an error:
ValueError: when `importance_getter=='auto'`, the underlying
estimator GaussianProcessClassifier should have `coef_` or
`feature_importances_` attribute. Either pass a fitted estimator to
feature selector or call fit before calling transform.
With SVC, I just solved this problem by putting a coefficient in the SVC with c_SVC = SVC(C = 1).
Is there any possible workaround here, since GPC doesn't have coefficients?