transformation/scale: Migrate code