Add helper functions, and chang scale to scale_to that is readable for source code