This check must be done in fit, not init: people can change the attribute (for instance using set_params) outside of the fit.