Refactoring to 1000x1000 grid