moved params inside do_minimisation