rebuild the map