creating map beforehand