move feature selection optimisation function script