Began refine codes step by step. Start from space scale