A stochastic scan strategy for grain structure control in complex geometries using electron beam powder bed fusion