Stochastic handling of tolerances in robust magnets design