Optimized the map.